Ads.

Pages

Tuesday, March 27, 2012

How to Insert Javascript in Blogger Template and Posts

Insert Javascript inside the Template
Visual Steps




Design > Edit HTML

Now you Search with Browser for the string "text/javascript"




Cmd+f on a Mac
Ctrl+f on a PC
Look for "text/javascript"


And...
Take Note of the Position you Found It! At Google there are Wise Guys and they Know that the Best Position to put Javascript Code for Site Functionality is: the End of the Body
The idea to put Javascript in the head has been largely diffused Simply because that the best way to keep Ordered and Readable your HTML Content... But now if you look at how HTML is Loading you will arrive to understand than it's Best to Load Before some Content and Images than Code. In Fact there is an Human Looking at the Screen and he Doesn't like so much Waiting in front a Blank or Messy Image :)

Check-Out this Testing Instruction:




This is to Check if you Blogger Template is all Right before to Complete the Setup Instructions...









Insert Highlighted Code to Test
Save Template


If you have Inserted an Alert command just Click on View BInsert Javascript in the Posts
If you need to Insert Javascript in your Post Look right to the Next Section.
Execute this Command:



Insert Code at the Post's Bottom
To Test Insert Highlighted Code
Publish and View Post to Verifylog to verify than is Working! :)

No comments:

Post a Comment