欢迎你的访问
 
返回天空素材库首页 http://www.Skysucai.com  
收藏本站
将本站设为首页
您当前的位置:天空素材首页 -> 提示特效打字效果
 
栏 目 导 航
. 常用代码 . 综合特效
. 状态特效 . 游戏特效
. 页面背景 . 页面特效
. 页面导航 . 文本操作
. 文本特效 . 图形特效
. 鼠标特效 . 时间日期
. 密码特效 . 浏览相关
. 警告对话 . 技巧特效
. 计数转换 . 测试搜索
. 代码生成 . 播放音乐
. 按钮特效 . 系统相关
. 链接特效 . 黑客性质
. 相关特效 . 窗口特效
. 广告特效 . 表单表格
. 模拟例子
相 关 文 章
· 状态栏显示链接内容...
· 又一例闪动的标题栏...
· 让标题栏文字动起来...
· 状态栏显示链接内容...
· 在输入框中输入什么...
· 状态栏打字效果特效...
· 闪动的标题栏特效
· 字符来回出现于状态...
· 在标题栏显示时间特...
· 一款状态滚动的文字...
本 类 热 门
· 网页十字显现
· 提示特效打字效果
· JScript实现的IP地址输...
· 随次数变化提示
· 弹出窗口自动关闭
· 离开页面弹出窗口
· 进入时显示信息
· 离开启动收藏夹
· 链接确认按钮
· 点击加入收藏夹
· 记录页面更新时间
· 页面载入等待
更多  
 
 
更多  
最 新 推 荐
· 状态栏时间跳动特效
· 农历挂历特效
· 真正的万年历
· 网页特效 菜单-会动的...
· 网页特效 时间-任意位...
· 个人网页特效-有前后日...
· 时间每过一秒,Radio就...
· 时钟显示在任意指定位...
· 带开关的Form时钟
· 记录几天后的日期
· 显示登陆时间
· 退出时显示访问时间
更多  
     
提示特效打字效果
提示特效打字效果
作者:佚名  来源:本站整理  名称:提示特效打字效果 

减小字体 增大字体

       

[提示:你可先按照下面代码提示修改 上面部分代码,再按运行,此处看到的演示不完全正确]

此特效的详细完整代码如下:

<html><head><title></title>

<script language=javaScript>
<!-- Beginning of JavaScript -

// CREDITS:
// PopupTicker describing all your links onmouseover by Urs Dudli and Peter Gehrig
// Copyright (c) 2000 Peter Gehrig and Urs Dudli. All rights reserved.
// Permission given to use the script provided that this notice remains as is.
// Additional scripts can be found at http://www.24fun.com.
// info@24fun.ch
// 8/1/2000

// IMPORTANT:
// If you add this script to a script-library or a script-archive
// you have to insert a link to http://www.24fun.com right into the webpage where the script
// will be displayed.

// CONFIGURATION:
// Go to http://www.24fun.com, open category 'text' and download the ZIP-file of this script
// containing the the script-file with step-by-step instructions for easy configuration.

// width of the ticker
var tickerwidth=120

// height of the ticker
var tickerheight=100

// distance from the messagetext to the tickermarrgin (pixels)
var tickerpadding=5

// borderwidth of the ticker (pixels)
var borderwidth=2

// font-family
var fnt="Verdana"

// font-size of the text
var fntsize=8

// font-size of the last letter of the ticker
var fntsizelastletter=8

// font-color of the text
var fntcolor="008800"

// font-color of the last letter of the ticker
var fntcolorlastletter="00AA00"

// font-weight. Set a value between 1 to 9 to adjust the boldness
var fntweight=3

// backgroundcolor
var backgroundcolor="CCFFCC"

// standstill between the messages (microseconds)
var standstill=2000

// speed (a higher value will slow down the ticker)
var speed=40

// horizontal distance from the textlink to the popupbox (pixels)
var xdistance=50

// vertical distance from the textlink to the popupbox (pixels)
var ydistance=20

// Do not edit the variables below
var timer
var topposition=0
var leftposition=0
var x,y
var i_substring=0
var i_presubstring=0
var i_message=0
var message
var messagecontent=""
var messagebackground=""
var messagepresubstring=""
var messageaftersubstring=""
fntweight=fntweight*100

function getmessagebackground() {
        messagebackground="<table border="+borderwidth+" width="+tickerwidth+" height="+tickerheight+" cellspacing=0 cellpadding=0><tr><td valign=top bgcolor='"+backgroundcolor+"'>"
        messagebackground+=" </td></tr></table>"
}

function getmessagecontent() {   
        messagecontent="<table border=0 cellspacing=0 cellpadding="+tickerpadding+" width="+tickerwidth+" height="+tickerheight+"><tr><td valign=top>"
        messagecontent+="<span style='position:relative; font-family:"+fnt+";color:"+fntcolor+";font-size:"+fntsize+"pt;font-weight:"+fntweight+"'>"   
        messagecontent+="<font color='"+fntcolor+"'>"
        messagecontent+=messagepresubstring
        messagecontent+="</font>"
        messagecontent+="</span>"
        messagecontent+="<span style='position:relative; font-family:"+fnt+";color:"+fntcolor+";font-size:"+fntsizelastletter+"pt;font-weight:900'>"   
        messagecontent+="<font color='"+fntcolorlastletter+"'>"
        messagecontent+=messageaftersubstring
        messagecontent+="</font>"
        messagecontent+="</span>"
        messagecontent+="</td></tr></table>"
}

function showticker() {
    if (i_substring<=message.length-1) {
            i_substring++
            i_presubstring=i_substring-1
            if (i_presubstring<0) {i_presubstring=0}
            messagepresubstring=message.substring(0,i_presubstring)
            messageaftersubstring=message.substring(i_presubstring,i_substring)
            getmessagecontent()
        if (document.all) {
            ticker.innerHTML=messagecontent
            timer=setTimeout("showticker()", speed)
        }
        if (document.layers) {
            document.ticker.document.write(messagecontent)
            document.ticker.document.close()
            timer=setTimeout("showticker()", speed)
        }
    }
    else {
        clearTimeout(timer)
    }
}

function hideticker() {
    clearTimeout(timer)
    i_substring=0
    i_presubstring=0
    if (document.all) {
        document.all.ticker.style.visibility="hidden"
        document.all.tickerbg.style.visibility="hidden"
    }
    if (document.layers) {
        document.ticker.visibility="hidden"
        document.tickerbg.visibility="hidden"
    }
}

function showmessage(linkmessage) {
    getmessagebackground()
    message=linkmessage
  
    i_substring=0
    i_presubstring=0
    leftposition=x+xdistance
    topposition=y+ydistance
    if (document.all) {   
        document.all.ticker.style.posLeft=leftposition
        document.all.ticker.style.posTop=topposition
        document.all.tickerbg.style.posLeft=leftposition
        document.all.tickerbg.style.posTop=topposition
        tickerbg.innerHTML=messagebackground
        document.all.ticker.style.visibility="visible"
        document.all.tickerbg.style.visibility="visible"
        showticker()
    }
    if (document.layers) {
        document.ticker.left=leftposition
        document.ticker.top=topposition
        document.tickerbg.left=leftposition
        document.tickerbg.top=topposition
        document.tickerbg.document.write(messagebackground)
        document.tickerbg.document.close()
        document.ticker.visibility="visible"
        document.tickerbg.visibility="visible"
        showticker()
    }
}

function handlerMM(e){
    x = (document.layers) ? e.pageX : document.body.scrollLeft+event.clientX
    y = (document.layers) ? e.pageY : document.body.scrollTop+event.clientY
}

if (document.layers){
    document.captureEvents(Event.MOUSEMOVE);
}
document.onmousemove = handlerMM;

// - End of JavaScript - -->
</script>

</head>
<body>
<DIV ID="tickerbg" style="position:absolute;"></DIV>
<DIV ID="ticker" style="position:absolute;"></DIV>

<a href="http://jojoo.net" onMouseOver="showmessage('欢迎来到jojoo.net')" onMouseOut="hideticker()">显示效果</a>

</body></html>

 

[返回上一页] [打印提示特效打字效果]
上一篇特效:鼠标经过变色文字
下一篇特效:网页十字显现
     
| 关于本站 | 服务条款 | 友情连接 | 网站地图 | 联系方式 | 广告联系 |