MyBB Community Forums

Full Version: [Tutorial]Adding Snow To Your Site
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
This tutorial will show how to add snow to your site using javascript. I will try to make this as easy as possible.

Step 1. Download the javascript file attached below and upload to your webserver /jscripts folder.
Step 2. Login to your admin panel, Go to Templates & Style,Templates(on the side) and pick yourtheme name Templates.
Step 3. Now go to Header Templates, and select header.
Step 4. Add in the following code to the top of your header box
<script type="text/javascript" src="http:/YOUR.SITE/jscripts/snowstorm.js"></script>
Step 5. Click Save and you now have snow!

If using for website place in <head> tags.
Nice work, but I would rather say adding the code to the headerinclude template, which is where all jscripts codes are. Templates > Ungrouped Templates (the last one on the list) > headerinclude.
It doesn't really matter. You can also add it in the footer to make your content load faster by a view miliseconds Toungue.
Why would it load faster? Sounds interesting. Would it work in plain HTML/CSS other than a forum?
Yes. It works.
I know this works in plain HTML/CSS websites. But I mean the script loading faster by placing the <script> tag on the footer or something..
Looking back at this, I have 1 thing to add.

If using for website place in <head> tags.
(2009-12-31, 12:17 AM)faviouz Wrote: [ -> ]Nice work, but I would rather say adding the code to the headerinclude template, which is where all jscripts codes are.
That's what I often do.Big Grin All of my scripts are mostly there rather than head tags etc.

on topic:
I like it. Just tested at localhost!Smile

working fine, one question is there anyway we can show it outside of the <div id="container">
That is so cute! I'm glad this was bumped, since it wouldn't have occurred to me to look that far back for snow. Smile

ETA Though I wouldn't call it a snowstorm. LOL Light flakes at best.