How To Create Snowing On A Web Page
Submitted by alpha_luna on Wednesday, May 18, 2016 - 14:53.
Snowing On A Web Page
In this article, we are going to learn on How To Create Snowing On A Web Page. Have you tried this? Have you seen snowing on your web page? This is how to create: In the code below, you can set the amount of snow, for the colors of the snow, the types of the snow, the speed of the snow, the max and min size of the snow, and the direction of the snow.- <script>
- // Set the number of snowflakes (more than 30 - 40 not recommended)
- var snowmax=30
- // Set the colors for the snow. Add as many colors as you like
- var snowcolor=new Array("#aaaacc","#ddddFF","#ccccDD")
- // Set the fonts, that create the snowflakes. Add as many fonts as you like
- var snowtype=new Array("Cursive","Helvitica","Times","Calibri")
- // Set the letter that creates your snowflake (recommended:*)
- var symbolOfTheSnow="*"
- // Set the speed of sinking (recommended values range from 0.3 to 2)
- var sinkspeed=1
- // Set the maximal-size of your snowflaxes
- var sizeOfTheSnow=50
- // Set the minimal-size of your snowflaxes
- var snowminsize=15
- // Set the snowing-zone
- // Set 1 for all-over-snowing, set 2 for left-side-snowing
- // Set 3 for center-snowing, set 4 for right-side-snowing
- var snowingzone=3
- </script>
Add new comment
- 179 views