您现在的位置: 万盛学电脑网 >> 程序编程 >> 网络编程 >> 安卓开发 >> 正文

如何让html5自动伸缩?

作者:佚名    责任编辑:admin    更新时间:2022-06-22

更有效的连接工作效率,使得基于页面的实时聊天,更快速的网页游戏体验,更优化的在线交流得到了实现。HTML5拥有更有效的服务器推送技术,Server-Sent Event和WebSockets就是其中的两个特性,这两个特性能够帮助我们实现服务器将数据“推送”到客户端的功能。下面我们给大家介绍一下html5自动伸缩吧!

  第一步把如下代码加入到<head>区域中

  <style type=text/css>
menulinks {position:relative;}
#menucont a{color:#; fontweight:bold; textdecoration:none;}
#menucont a:hover{color:#ff; fontweight:bold; textdecoration:underlineoverline; texttransform: uppercase;}
</style>
<script LANGUAGE=Javascript>
<! Begin
nSpace=   // how many space maximum between each letter
nSpeed= // the speed of the animation
timerLSM=null;
function LetterSpacingMenu() {
if(documentgetElementById){
   lnks = Mathfloor(Mathrandom()*lnklength);
   letterSpacing = Mathfloor(Mathrandom()*nSpace);
   lnk[lnks]style