Javascript考试题目选择题doc.docx

上传人:b****1 文档编号:1662817 上传时间:2022-10-23 格式:DOCX 页数:26 大小:29.27KB
下载 相关 举报
Javascript考试题目选择题doc.docx_第1页
第1页 / 共26页
Javascript考试题目选择题doc.docx_第2页
第2页 / 共26页
Javascript考试题目选择题doc.docx_第3页
第3页 / 共26页
Javascript考试题目选择题doc.docx_第4页
第4页 / 共26页
Javascript考试题目选择题doc.docx_第5页
第5页 / 共26页
点击查看更多>>
下载资源
资源描述

Javascript考试题目选择题doc.docx

《Javascript考试题目选择题doc.docx》由会员分享,可在线阅读,更多相关《Javascript考试题目选择题doc.docx(26页珍藏版)》请在冰豆网上搜索。

Javascript考试题目选择题doc.docx

Javascript考试题目选择题doc

复习题

一、选择题

1、写“HelloWorld”的正确javascript语法是?

(A)

A.document.write("HelloWorld")B."HelloWorld"

C.response.write("HelloWorld")D.("HelloWorld")

2、」S特性不包括(D)

A.解释性B.用于客户端C.基于对象D.面向对象

3、下列jS的判断语句中(}是正确的(A)

A.if(i==O)B.if(i=O)C.ifi==0thenD.ifi=0then

4、卜列javaScript的循环语句中()是正确的(D)

A.if(i<10;i++)B.for(i=0;i<10)

C.fori=lto10D.for(i=0;i<=10;i++)

5、下列的哪一个表达式将返回假(B>

A.!

(3<=1)b.(4>=4)&&(5<=2)

C.("a"==〃a")&&("c"!

="d"}D.(2<3)||(3<2)

6、下列选项屮,(}不是网页屮的事件(D>

A.onclickB.onmouseoverC.onsubmitD.onpressbutton

7、有语句"varx=0;while(_)x+=2;”,要使while循环体执行10次,空白处的循环判定式应写为:

(C)

A.x<10B.x<=10C.x<20D.x<=20

8、jS语句(B)

varal=10;

vara2=20;

alert("al+a2="+al+a2)

将显示()结果

A.al+a2=30B.al+a2=1020C.al+a2=al+a2

9、将字串s中的所有字母变为小写字母的方法是(B>

A.s.toSmallCase()B.s.toLowerCase()

C.s.toUpperCase()D.s.toUpperChars()

10、以下()表达式产生一个0〜7之间(含0,7)的随机整数.(C)

A.Math.floor(Math.random()*6)

B.Math.floor(Math.random()*7)

C.Math.floor(Math.random()*8)

D.Math.ceil(Math.random()*8)

11、产生当前日期的方法是(C)

A.Now();B.Date()C.newDate()D.newNow()

12、如果想在网页S示后,动态地改变网页的标题(C)

A.是不可能的B.通过document.write("新的标题内容")

C.通过document.title=("新的标题内容〃)

D.通过document.changeTitle("新的标题内容w)

13、某网页屮有一个窗体对象,其名称是mainForm,该窗体对象的第一个元素是按钮,其名称

是myButton,表述该按钮对象的方法是(B)

A.document.forms.myButtonB.document.mainForm.myButton

C.document.forms[0].element[0]D.以上都可以

14、HTML文档的树状结构屮,()标签为文档的根节点,位于结构屮的最顶层。

(A)

A.B.C.D.</p><p>15、在HTML贞曲‘中,CSS样式的属性名为background-image对应的style对象的属性名是</p><p>(B)</p><p>A.backgroundB.backgrounglmageC.imageD.background</p><p>16、在使用Javascript实现省市级联菜单功能时,在添加城市列表前清空原来的下拉选项的代码是(C)</p><p>A.document.myform.selCity.options.clear()</p><p>B.document.myform.selCity.options.deleteAIIO</p><p>C.document.myform.selCity.options.length=0</p><p>D.document.myform.selCity.options.size=0</p><p>17、HMTL表单的首要标记是<form>,<form>标记的参数method表示表单发送的方法,可能为get或post,下列关于get和post的描述正确的是(D)</p><p>A.post方法传递的数据对客户端是不可见的</p><p>B.get请求信息以查询字符串的形式发送,查询字符串长度没有大小限制</p><p>C.post方法对发送数据的数量限制在255个字符之闪</p><p>D.get方法传递的数据对客户端是不可见的</p><p>18、在DOM对象模型中,下列选项中的()对象位于DOM对象模型的第二层。</p><p>(选择二</p><p>项)(AB)</p><p>A.historyB.documentC.buttonD.text</p><p>19、在HTML文档对象模型屮,history对象的()用于加载历史列表屮的下一个URL页而</p><p>(C)</p><p>A.next()B.backOC.forwardOD.go(-l)</p><p>20、在javascript巾要改变页面文档的背景色,$要修改document对象的()属性。</p><p>(C)A.BackColorB.BackgroundColorC.BgColorD.Background</p><p>21、在HTML页而屮,不能与onChange事件处理程序相关联的表单元素有(D)</p><p>A.文本框B.复选框C.列表框D.按钮</p><p>22、在HTML页面上编写javascript代码时,应编写在()标签中间。</p><p>⑻</p><p>A.<javascript>W</javascript>B.<script>/fD</script>C.<head>^n</head>D.<body>^H</body></p><p>23、在javascript浏览器对象模型中,window对象的()属性用来指定浏览器状态栏中显</p><p>示的临时消息。</p><p>(A></p><p>A.statusB.screenC.historyD.document</p><p>24、编写javascript函数实现网页背景色选择器,下列选项中正确的是(B)</p><p>A.functionchange(color){</p><p>window.bgColor=color;</p><p>}</p><p>B.functionchange(color){</p><p>document.bgColor=color;</p><p>}</p><p>C.functionchange(color){</p><p>body.bgColor=color;</p><p>}</p><p>D.functionchange(color){</p><p>form.bgColor=color;</p><p>}</p><p>25、在javascript中,可以使用Date对象的()方法返冋一个月中的每一天。</p><p>(A)</p><p>A.getDateB.getYearC.getMonthD.getTime</p><p>26、在javascript中,对于浏览器对象的层次关系理解正确的是()(选择二项)(AD)</p><p>A.window对象是所有页面内容的根对象</p><p>B.document对象包含location对象和history对象</p><p>C.location对象包含history</p><p>D.document对象包含form对象</p><p>27、下列选项巾关于浏览器对象的说法错误的是(C)</p><p>A.history对象记录了用户在一个浏览器中己经访问过的URLs</p><p>B.location对象相当于IE浏览器屮的地址栏,包含关于当前URL地址的信息</p><p>C.location对象是history对象的父对象</p><p>D.location对象是window对象的丫•对象</p><p>28、在HTML页面巾包含一个按钮控件mybutton,如果要实现点击该按钮时调用已定义的Javascript函数compute,要编写的HTML代码是(D)</p><p>Axinputname="mybutton"type="button"onBlur="compute()"value="计算w></p><p>B.cinputname=?</p><p>mybuttonwtype=/,button,/onFocus=,,compute()〃value=”计算w〉</p><p>Cxinputname=〃mybutton〃type="button"onClick=,,functioncompute()"value=U-算"〉Dxinputname="mybutton〃type="button"onClick="compute()"value=S"b算"〉</p><p>29、分析下面的Javascript代码段,输出结果是(C)varmystring=〃lamastudent";</p><p>vara=mystring.substring(9,13);document.write(a);</p><p>A.studB.tudenC.udenD.udent</p><p>30、Javascript中制作图片代替按钮的提交效果需要手动提交方法submitf),以下调用正确的是(C)</p><p>A.submit();B.myform.submit()C.document.myform.submit))D.window.myform.submit();</p><p>31、在HTML页面中包含如下所示代码,贝■写Javascript函数判断是否按下键盘上的回车键正确的编码是(C)</p><p>〈inputname="password"type=〃text"onkeydown="myKeyDown()"></p><p>1.functionmyKeyDown(){if(window.keyCode==13)</p><p>alert("你按下了回车键〃>;</p><p>2.functionmyKeyDown(){if(document.keyCode==13)</p><p>alert("你按下了回车键〃>;</p><p>3.functionmyKeyDown(){if(event.keyCode==13)</p><p>alert("你按下了回车键〃>;</p><p>4.functionmyKeyDown(){if(keyCode==13)</p><p>alert("你按下了回车键</p><p>32、如果在HTML页面中包含如下图片标签,则选项中的()语句能够实现隐藏该图片的</p><p>功能。</p><p>(D)</p><p><imgid="pic"src="Sunset.jpg〃width="400"height="300"></p><p>A.document.getElementByld(zzpic,,).style.display=,,visible,/;</p><p>B.document.getElementByld(z/pic,,).style.display=,,disvjsible,,;</p><p>C.document.getElementByld("pic").style.display="block";</p><p>D.document.getElementByld("pic〃).style.display=〃none";</p><p>33、如果在HTML页而屮包含如下图片标签,则在下划线处添加()代码能够实现隐藏该罔片的功能。</p><p>(D></p><p><imgid="pic"src="Sunset.jpg〃width="400"height="3OO〃></p><p>A.style="chsplay:</p><p>visible";</p><p>B.style=〃display:</p><p>disvisible〃;</p><p>C.style="display:</p><p>block";</p><p>D.style="display:</p><p>none”;</p><p>34、下列选</p> </div> <div class="readmore" onclick="showmore()" style="background-color:transparent; height:auto; margin:0px 0px; padding:20px 0px 0px 0px;"><span class="btn-readmore" style="background-color:transparent;"><em style=" font-style:normal">展开</em>阅读全文<i></i></span></div> <script> function showmore() { $(".readmore").hide(); $(".detail-article").css({ "height":"auto", "overflow": "hidden" }); } $(document).ready(function() { var dh = $(".detail-article").height(); if(dh >100) { $(".detail-article").css({ "height":"100px", "overflow": "hidden" }); } else { $(".readmore").hide(); } }); </script> </div> <script> var defaultShowPage = parseInt("5"); var id = "1662817"; var total_page = "26"; var mfull = false; var mshow = false; function DownLoad() { window.location.href='https://m.bdocx.com/down/1662817.html'; } function relate() { var reltop = $('#relate').offset().top-50; $("html,body").animate({ scrollTop: reltop }, 500); } </script> <script> var pre = "https://file1.bdocx.com/fileroot1/2022-10/20/040c9a78-4c01-496b-bcde-03f9dd21dfbd/040c9a78-4c01-496b-bcde-03f9dd21dfbd"; var freepage = parseInt('20'); var total_c = parseInt('26'); var start = defaultShowPage; var adcount = 0; var adindex = 0; var adType_list = ";0;1;2;3;4;5;6;7;8;9;10;11;12;13;14;15;16;17;18;19;"; var end = start; function ShowSvg() { end = start + defaultShowPage; if (end > freepage) end = freepage; for (var i = start; i < end; i++) { var imgurl = pre + (i + 1) + '.gif'; var html = "<img src='" + imgurl + "' onerror=\"this.src='/images/s.gif'\" alt=\"Javascript考试题目选择题doc.docx_第" + (i + 1) + "页\" width='100%'/>"; $("#page").append("<div class='page'>" + html + "</div>"); $("#page").append("<div class='pageSize'>第" + (i + 1) + "页 / 共" + total_c + "页</div>"); if(adcount > 0 && adType_list.indexOf(";"+(i+1)+";")>-1) { if(adindex > (adcount-1)) adindex = 0; $("#page").append("<div class='pagead' id='addiv"+(i + 1)+"'></div>"); document.getElementById("addiv"+(i + 1)+"").innerHTML =document.getElementById("adpre" + adindex).outerHTML; adindex += 1; } } start = end; if (start > (freepage - 1)) { if (start < total_c) { $("#pageMore").removeClass("btnmore"); $("#pageMore").html("亲,该文档总共" + total_c + "页,到这儿已超出免费预览范围,如果喜欢就下载吧!"); } else { $("#pageMore").removeClass("btnmore"); $("#pageMore").html("亲,该文档总共" + total_c + "页全部预览完了,如果喜欢就下载吧!"); } } } //$(document).ready(function () { // ShowSvg(); //}); </script> <div id="relate" class="container" style="padding:0px 0px 15px 0px; margin-top:20px; border:solid 1px #dceef8"> <div style=" font-size: 16px; background-color:#e5f0f7; margin-bottom:5px; font-weight: bold; text-indent:10px; line-height: 40px; height:40px; padding-bottom: 0px;">相关资源</div> <div id="relatelist" style="padding-left:5px;"> <ul> <li><em class="docx"/></em><a target="_parent" href="https://m.bdocx.com/doc/30860712.html" title="保安员各岗位工作方法与技巧.docx">保安员各岗位工作方法与技巧.docx</a> </li><li><em class="docx"/></em><a target="_parent" href="https://m.bdocx.com/doc/30860711.html" title="物业公司全年绿化养护管理措施.docx">物业公司全年绿化养护管理措施.docx</a> </li><li><em class="docx"/></em><a target="_parent" href="https://m.bdocx.com/doc/30860710.html" title="物业服务品质提升方案.docx">物业服务品质提升方案.docx</a> </li><li><em class="docx"/></em><a target="_parent" href="https://m.bdocx.com/doc/30860709.html" title="不同类型物业的物业管理.docx">不同类型物业的物业管理.docx</a> </li><li><em class="docx"/></em><a target="_parent" href="https://m.bdocx.com/doc/30860708.html" title="物业消防演习方案及步骤(超实用).docx">物业消防演习方案及步骤(超实用).docx</a> </li><li><em class="docx"/></em><a target="_parent" href="https://m.bdocx.com/doc/30860707.html" title="物业管理知识填空题含答案.docx">物业管理知识填空题含答案.docx</a> </li><li><em class="docx"/></em><a target="_parent" href="https://m.bdocx.com/doc/30860706.html" title="物业管理试题含答案.docx">物业管理试题含答案.docx</a> </li><li><em class="docx"/></em><a target="_parent" href="https://m.bdocx.com/doc/30860705.html" title="物业奖罚标准范本.docx">物业奖罚标准范本.docx</a> </li><li><em class="docx"/></em><a target="_parent" href="https://m.bdocx.com/doc/30860704.html" title="物业工程培训资料.docx">物业工程培训资料.docx</a> </li><li><em class="docx"/></em><a target="_parent" href="https://m.bdocx.com/doc/30860703.html" title="小区和大厦巡逻记录表.docx">小区和大厦巡逻记录表.docx</a> </li> </ul> </div> </div> <div class="container" style="padding:0px 0px 15px 0px; margin-top:20px; border:solid 1px #dceef8"> <div style=" font-size: 16px; background-color:#e5f0f7; margin-bottom:5px; font-weight: bold; text-indent:10px; line-height: 40px; height:40px; padding-bottom: 0px;">猜你喜欢</div> <div id="relatelist" style="padding-left:5px;"> <ul> <li><em class="docx"></em> <a href="https://m.bdocx.com/doc/522352.html" target="_parent" title="自愿离职协议书正规版.docx">自愿离职协议书正规版.docx</a></li> <li><em class="docx"></em> <a href="https://m.bdocx.com/doc/522353.html" target="_parent" title="天津企业博士后创新项目.docx">天津企业博士后创新项目.docx</a></li> <li><em class="docx"></em> <a href="https://m.bdocx.com/doc/522354.html" target="_parent" title="最新版精编《单片机与接口技术》完整版考核题库158题含答案.docx">最新版精编《单片机与接口技术》完整版考核题库158题含答案.docx</a></li> <li><em class="docx"></em> <a href="https://m.bdocx.com/doc/522355.html" target="_parent" title="阿联酋法律体系.docx">阿联酋法律体系.docx</a></li> <li><em class="docx"></em> <a href="https://m.bdocx.com/doc/522356.html" target="_parent" title="爱因斯坦的名言警句摘抄.docx">爱因斯坦的名言警句摘抄.docx</a></li> <li><em class="docx"></em> <a href="https://m.bdocx.com/doc/522357.html" target="_parent" title="深圳行测资料分析真题解析.docx">深圳行测资料分析真题解析.docx</a></li> <li><em class="docx"></em> <a href="https://m.bdocx.com/doc/522358.html" target="_parent" title="最新年度审计报告及附注模板资料.docx">最新年度审计报告及附注模板资料.docx</a></li> <li><em class="docx"></em> <a href="https://m.bdocx.com/doc/522359.html" target="_parent" title="安徽省普通高中学生综合素质评价纪实报告模板.docx">安徽省普通高中学生综合素质评价纪实报告模板.docx</a></li> <li><em class="docx"></em> <a href="https://m.bdocx.com/doc/522360.html" target="_parent" title="最新精编北京市安全生产专职安全员模拟考核题库500题含标准答案.docx">最新精编北京市安全生产专职安全员模拟考核题库500题含标准答案.docx</a></li> </ul> </div> </div> <div style=" font-size: 16px; background-color:#e5f0f7; margin-top:20px; font-weight: bold; text-indent:10px; line-height: 40px; height:40px; padding-bottom: 0px; margin-bottom:10px;"> 相关搜索</div> <div class="widget-box pt0" style="border: none; padding:0px 5px;"> <ul class="taglist--inline multi"> <li class="tagPopup"><a target="_parent" class="tag tagsearch" rel="nofollow" href="https://m.bdocx.com/search.html?q=Javascript">Javascript</a></li> <li class="tagPopup"><a target="_parent" class="tag tagsearch" rel="nofollow" href="https://m.bdocx.com/search.html?q=%e8%80%83%e8%af%95">考试</a></li> <li class="tagPopup"><a target="_parent" class="tag tagsearch" rel="nofollow" href="https://m.bdocx.com/search.html?q=%e9%a2%98%e7%9b%ae">题目</a></li> <li class="tagPopup"><a target="_parent" class="tag tagsearch" rel="nofollow" href="https://m.bdocx.com/search.html?q=%e9%80%89%e6%8b%a9%e9%a2%98">选择题</a></li> <li class="tagPopup"><a target="_parent" class="tag tagsearch" rel="nofollow" href="https://m.bdocx.com/search.html?q=doc">doc</a></li> </ul> </div> <br /> <div > 当前位置:<a target="_parent" href="https://m.bdocx.com/">首页</a> > <a href="https://m.bdocx.com/booklist-00002.html">经管营销</a><span> > </span><a href="https://m.bdocx.com/booklist-0000200007.html">公共行政管理</a> </div> <br /> <div class="cssnone"> <iframe title="来源" src="https://m.bdocx.com/BookRead.aspx?id=LDqW5F3ijnI%3d&parto=OWp70ctBoiZVSzdc8K2tykfPcMi2UrPrGitqmP99r2YNXlNrMgDUIN%2f9X48ai8i9wEVRkDxA3oHwA%2fFNB1TOlXXYR8s%2bGtakJPwLqkhVup%2bbgczBAGJMs5sqglwdArVGq0UDMmV2kTpH1F4WkVcNnPRcbx1KbSZCfhvneakw8FtaB%2bbV9dgDAb9a6Pt%2bE5o1RwYIOBGSavlJvSIW4Sq3Si%2bcXza1jktX" frameborder="0" style="width: 0px; height: 0px"> </iframe> </div> <span id="LabelScript"></span> <script src="https://mstatic.bdocx.com/JS/bootstrap-collapse.js"></script> </form> <div class="siteInner_bg" style="margin-top: 40px; border: solid 0px red; margin-left: 0px; margin-right: 0px;"> <div class="siteInner"> <p style="text-align: center;">copyright@ 2008-2022 冰豆网网站版权所有</p><p style="text-align: center;">经营许可证编号:<a href="http://beian.miit.gov.cn/" target="_blank">鄂ICP备2022015515号-1</a></p><script>var _hmt = _hmt || []; (function() { var hm = document.createElement("script"); hm.src = "https://hm.baidu.com/hm.js?2e77bd3f6fe91b0e21d3f22267249ee3"; var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(hm, s); })();</script><script>(function(){ var el = document.createElement("script"); el.src = "https://lf1-cdn-tos.bytegoofy.com/goofy/ttzz/push.js?81476e42bf626128cf29544ee216a8ed7deb9487dce7ed62313212129c4244a219d1c501ebd3301f5e2290626f5b53d078c8250527fa0dfd9783a026ff3cf719"; el.id = "ttzz"; var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(el, s); })(window)</script> </div> </div> <div class="trnav clearfix" id="navcontent" style="display: none; background-color:#3a71b1; "> <div class="trlogoside" id="navlogo" style="display: none;"> <a href="https://m.bdocx.com/" title="冰豆网"><img src="https://www.bdocx.com/images/logo_bd.png" alt="冰豆网"></a> <div class="trnavclose" id="navclose"> <span></span> </div> </div> <div class="navcontainer"> <div class="row"> <ul class="nav navbar-nav trnavul headercontent" id="navigation" style="margin:20px 0 0px;"> <li><a target="_parent"href="https://m.bdocx.com/login.aspx">登录</a></li> <li><a target="_parent"href="https://m.bdocx.com/">首页 </a></li> <li><a target="_parent"href="https://m.bdocx.com/booklist-0.html">资源分类 </a></li> <li><a target="_parent"href="https://m.bdocx.com/UserManage/Recharge.aspx?f=0"><img src="https://m.bdocx.com/images/s.gif" alt="new" class="hottip1">升级会员 <img src="https://www.bdocx.com/FileUpload/Images/48520fea-bc98-41ae-b183-84689c7075c9.gif" alt="new" class="hottip"></a></li> <li><a target="_parent"href="https://m.bdocx.com/newslist.html">通知公告 </a></li> <li><a target="_parent"href="https://m.bdocx.com/h-0.html">帮助中心 </a></li> </ul> </div> </div> </div> <script type="text/javascript"> function stopPropagation(e) { var ev = e || window.event; if (ev.stopPropagation) { ev.stopPropagation(); } else if (window.event) { window.event.cancelBubble = true;//兼容IE } } $("#navmore").click(function (e) { $("#navcontent").show(); $("#navlogo").show(); stopPropagation(e); var navcontentwidth = $("#navcontent").width(); $('#navcontent').css({ 'right': '-' + navcontentwidth + 'px' }); $("#navcontent").show().animate({ "right": 0 }, 300); }); $(document).bind('click', function () { var navcontentwidth = $("#navcontent").width(); $("#navcontent").animate({ 'right': '-' + navcontentwidth + 'px' }, 300, function () { $("#navcontent").hide(); }); $("#navlogo").fadeOut(300); }); $("#navcontent").click(function (e) { stopPropagation(e); }); $("#navclose").click(function (e) { var navcontentwidth = $("#navcontent").width(); $("#navcontent").animate({ 'right': '-' + navcontentwidth + 'px' }, 300, function () { $("#navcontent").hide(); }); $("#navlogo").fadeOut(300); }); </script> <script> function BaseShare(title, desc, imgUrl) { var link = "https://m.bdocx.com/doc/1662817.html"; if (wx) { wx.config({ debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。 appId: 'wx4f717640abfd1120', // 必填,公众号的唯一标识 timestamp: '1720865752', // 必填,生成签名的时间戳 nonceStr: 'DD45045F8C68DB9F54E70C67048D32E8', // 必填,生成签名的随机串 signature: '0b177f6fa5f0491adc91bee0fbaf3aef93907099',// 必填,签名,见附录1 jsApiList: ['onMenuShareAppMessage', 'onMenuShareTimeline', 'updateAppMessageShareData', 'updateTimelineShareData', 'hideMenuItems'] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2 //openTagList: ["wx-open-launch-weapp"]//H5打开小程序 }); wx.ready(function () { //需在用户可能点击分享按钮前就先调用 wx.hideMenuItems({// 要隐藏的菜单项,只能隐藏“传播类”和“保护类”按钮,所有menu项见附录3 menuList: ['menuItem:share:qq', 'menuItem:favorite', 'menuItem:share:QZone', 'menuItem:share:email', 'menuItem:originPage', 'menuItem:readMode', 'menuItem:delete', 'menuItem:editTag', 'menuItem:share:facebook', 'menuItem:share:weiboApp', 'menuItem:share:brand'] }); var shareData = { title: title, // 分享标题 desc: desc,//这里请特别注意是要去除html link: link, // 分享链接,该链接域名或路径必须与当前页面对应的公众号JS安全域名一致 imgUrl: imgUrl, // 分享图标 }; wx.updateAppMessageShareData(shareData);//1.4 分享到朋友 wx.updateTimelineShareData(shareData);//1.4分享到朋友圈 }); } } function BaseShare(title, desc, imgUrl, link) { if (link=="") link = "https://m.bdocx.com/doc/1662817.html"; if (wx) { wx.config({ debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。 appId: 'wx4f717640abfd1120', // 必填,公众号的唯一标识 timestamp: '1720865752', // 必填,生成签名的时间戳 nonceStr: 'DD45045F8C68DB9F54E70C67048D32E8', // 必填,生成签名的随机串 signature: '0b177f6fa5f0491adc91bee0fbaf3aef93907099',// 必填,签名,见附录1 jsApiList: ['onMenuShareAppMessage', 'onMenuShareTimeline', 'updateAppMessageShareData', 'updateTimelineShareData', 'hideMenuItems'] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2 //openTagList: ["wx-open-launch-weapp"]//H5打开小程序 }); wx.ready(function () { //需在用户可能点击分享按钮前就先调用 wx.hideMenuItems({// 要隐藏的菜单项,只能隐藏“传播类”和“保护类”按钮,所有menu项见附录3 menuList: ['menuItem:share:qq', 'menuItem:favorite', 'menuItem:share:QZone', 'menuItem:share:email', 'menuItem:originPage', 'menuItem:readMode', 'menuItem:delete', 'menuItem:editTag', 'menuItem:share:facebook', 'menuItem:share:weiboApp', 'menuItem:share:brand'] }); var shareData = { title: title, // 分享标题 desc: desc,//这里请特别注意是要去除html link: link, // 分享链接,该链接域名或路径必须与当前页面对应的公众号JS安全域名一致 imgUrl: imgUrl, // 分享图标 }; wx.updateAppMessageShareData(shareData);//1.4 分享到朋友 wx.updateTimelineShareData(shareData);//1.4分享到朋友圈 }); } } </script> <script> $(document).ready(function () { var arr = $(".headercontent"); for (var i = 0; i < arr.length; i++) { (function (index) { var url = "https://m.bdocx.com/header.aspx"; $.get(url + "?t=" + (new Date()).valueOf(), function (d) { try { arr.eq(index).empty().html(d); } catch (e) { } try { arr.html(d); } catch (e) { } }); })(i); } }); </script> <script src="https://mstatic.bdocx.com/js/jquery.lazyload.js"></script> <script charset="utf-8"> $("img.lazys").lazyload({ threshold: 200, effect: "fadeIn" }); </script> </body> </html>