Technology Programming

How to Animate a Background With CSS

    • 1). Launch your Web editing application, and open the HTML code for the webpage you want to modify.

    • 2). Type "<STYLE type="text/css"> <!--" at the very top of the HTML code to create a new CSS stylesheet.

    • 3). Leave a few blank lines after the starting CSS tag, then type "--> </STYLE>" into the HTML code. This tag will mark the end of the CSS stylesheet.

    • 4). Place your text cursor in between the two "STYLE" tags you just entered.

    • 5). Type "BODY { background-image:URL(http://mysite.com/animation.gif) }" into the code.

    • 6). Replace "http://mysite.com/animation.gif" with the exact URL for the animated GIF file that you want to use as a background.

    • 7). Save the HTML code, and upload it to your active Web server. The animated GIF file you specified will now be used as the background for your webpage.



Leave a reply