第一步:把如下代码加入<head>区域中
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
function initArray() {
for (var i = 0; i < initArray.arguments.length; i++) {
this = initArray.arguments;
}
this.length = initArray.arguments.length;
}
var colors = new initArray(
"red",
"blue",
"green",
"purple",
"black",
"tan",
"yellow",
"lime",
"coral",
"palegreen",
"silver",
"gold",
"red");
delay = .5; // seconds
link = 0;
vlink = 0;
function linkDance() {
link = (link+1)%colors.length;
vlink = (vlink+1)%colors.length;
document.linkColor = colors[link];
document.vlinkColor = colors[vlink];
setTimeout("linkDance()",delay*1000);
}
linkDance();
// End -->
</script>

那么链接处就会出现彩色字体
注意:不能在<style>中定义好链接颜色

相关文章:

  • 2021-12-16
  • 2021-06-02
  • 2022-01-14
  • 2021-11-18
  • 2021-12-14
  • 2021-12-10
猜你喜欢
  • 2021-11-15
  • 2022-12-23
  • 2021-07-29
  • 2021-09-02
  • 2022-12-23
  • 2022-01-16
相关资源
相似解决方案