Feeds:
Posts
Comments

Archive for the ‘Javascript’ Category

<style type=”text/css”> tr.s1{ background-color: #e0e0e0; color: black; } tr.s2{ background-color: #ffffff; color: black; } </style> <table> <tr class=”s1″><td>ciao</td><td>come</td></tr> <tr class=”s2″><td>stai</td><td>io</td></tr> <tr class=”s1″><td>bene</td><td>grazie</td></tr> <tr class=”s2″><td>saluti</td><td>ciao</td></tr> </table>

Read Full Post »

Suppose you have a block of text you want to be collapsible clicking a link. Here is the code: <script language=”javascript”>   function switchDiv(id_div)   {     if(document.getElementById(id_div).style.display == ‘none’)     {    document.getElementById(id_div).style.display = ‘block’;     }     else     {    document.getElementById(id_div).style.display = ‘none’;     }   } </script>

Read Full Post »

There are 2 methods to redirect html pages. The first one is pure HTML. The second one is done with Javascript. HTML Method insert this line inside the <head> … </head> block: <meta http-equiv=”refresh” content=”num_sec; URL=new_web_address”> where num_sec is the number of seconds to wait before redirection new_web_address is the new relative or absolute URL [...]

Read Full Post »

Follow

Get every new post delivered to your Inbox.