随笔-46  评论-64  文章-2  trackbacks-0
< link id = " css "  rel = StyleSheet type = " text/css "  href = " ./button.css "   />

< script type = " text/javascript " >
 
var  cssArray  =   new  Array( " button.css " , " button1.css " , " button2.css " , " button3.css " , " button4.css " , " button5.css " , " button6.css " );
 
var  index  =   0 ;
 
function  changeCssFile()
 
{
  
var  css  =  document.getElementById( " css " );
  index
++ ;
  
if (index < cssArray.length)
  
{
   css.href 
=  cssArray[index];
  }

  
else
  
{
   index 
= 0 ;
   css.href 
=  cssArray[index];
  }

 }

</ script >

  < class ="button"  href ="#"  onclick ="changeCssFile()" >
  
< span  id ="buttonText" > Change another style </ span >
 
</ a >
posted on 2008-09-25 12:26 jht 阅读(752) 评论(0)  编辑  收藏

只有注册用户登录后才能发表评论。


网站导航: