Advertisements from such companies as Add Bright, Adsense and Buysellads.
Embedding flash – for example: YouTube videos, Video players and games.
Share Icons/widgets such as facebook, linkedin, twitter, etc.
Printing dynamic content to the screen such as dates, times, user names, etc.
Do you want to try it for yourself? Simply go to http://www.ooso.net/inline-js and download it. It doesn’t get much easier than that and using the tags like above.
First wrap everything in functions. If you have to use more than one or two functions, then you probably want to consider an alternative method for employing the scripts in your posts or pages such as a template file or child theme. More advanced users will more likely chose those alternative methods most of the time anyway.
Upload your script with your functions in it to a scripts directory in your main WordPress directory. That will be the same directory that holds the wp-content and wp-admin folders among other stuff. If you don’t have a scripts directory, create one there.
Finally insert the function call on the next line in your post or page. It should look something like this: