随笔分类 - Javascript
摘要:function StranText(txt, toFT, chgTxt) { alert(txt); if (txt == "" || txt == null) return ""; toFT = toFT == null ? BodyIsFt : toFT; // if (toFT == 1) { // alert(toFT); // } // else if (toFT == 0) { // alert("N" + toFT); // } if (toFT==1) { alert(toFT); } else { alert(&q
阅读全文
摘要:<SCRIPT type=text/javascript>kfguin="859762134";eid="";ws="www.hello3w.cn"; companyname="漂泊者梦想"; welcomeword="您好,请问有什么可以效劳吗?"; type="1";wpadomain="bizapp";</SCRIPT><SCRIPT type=text/javascript src="http://im.bi
阅读全文
摘要:请用"\n"如果这个不可以的话就是"\\n"比如:<script type="text/javascript">alert("hello \n world!");</script>
阅读全文
摘要:首先,解决这个问题,也花了很多时间!主要是下面一段话,在百度里面摆到了好几遍“在script中使用defer属性。意在页面加载完毕后再执行脚本,这样可以避免找不到对象的问题。defer不会考虑外部文件是否全部下载完,只会判当前页面是否全部加载完成。并且,有defer标签的代码块里不能写document.write方法 例如<script language="javascript" type="text/javascript" src="temp/tooltip.js" defer="defer"><
阅读全文
摘要:今天遇到一个奇怪的问题,在服务器端通过c# 获取当前时间为 Fri Aug 28 09:37:46 CST 2009, 转化为GMT时间为:28 Aug 2009 01:37:46 GMT,也就是说GMT时间加上 8 个小时等于CST表示的时间, 那这个CST不就是北京时间么,因为我们是在东八区的。 一切看起来很正常,不过在客户端用JavaScript解析这个时间就有问题了: // Fri Aug 28 2009 23:37:46 GMT+0800 new Date('Fri Aug 28 09:37:46 CST 2009').toString(); 好奇怪,这次GMT和CS
阅读全文
摘要:.net中的checkbox控件貌似好像不能实现单选的!所以,我这边用jquery实现了!虽然很简单,但是,毕竟也是作了一番思考的!<h4> 产品搜索:</h4> <asp:DropDownList ID="DropDownList1" runat="server"> <asp:ListItem>请选择产品的用途:</asp:ListItem> </asp:DropDownList> <ul> <li>1.产品更注重环保 <asp:CheckBox ID
阅读全文
摘要:js代码Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/--> 1 <script language="javascript" type="text/javascript"> 2 document.write("网页可见区域宽:"+document.body.clientWidth+"<br/>"); 3 document.write("
阅读全文
浙公网安备 33010602011771号