草庐IT

properties_container

全部标签

c# - SCRIPT5009 : 'JSON' is undefined in IE 10 The value of the property '$' is null or undefined, 不是函数对象

HelloWorld$(document).ready(function(){});$(document).ready(function(){$("#width").val($(window).width());$("#height").val($(window).height());});上面是我的aspx代码和jquery脚本,它给出了窗口的高度和宽度。当我从visualstudiohttp://localhost/Mypage.aspx运行web应用程序时,这段代码在所有浏览器上都完美无缺但是当我在iis上托管它并使用我的机器名称http://MyMachine/Mypage.a

javascript - JQuery UI slider 未捕获类型错误 : Cannot read property 'addClass' of undefined

我已经检查了SO上的所有问题,但似乎找不到答案。如果我将整数直接放入字段中,那么这是可行的,但我想在设置脚本时动态设置参数我正在运行JQuery1.11.1、JQueryUI稳定版(1.11.0)和touchpunch。我已经调试过,变量都存在并在调用时初始化。我也试过用相同的结果包装自执行函数。(滑动功能可以忽略)这会抛出异常编辑我刚刚注意到,如果我单击slider,则会抛出异常,但如果我随后按下右箭头键,则不会抛出异常,并且金额会填充value属性。我在问题的末尾粘贴了控制台输出。$("#slider").slider({value:parseInt(window.settings

javascript - "The property or field ' 尝试通过 JavaScript 访问 SharePoint 中库的 GUID 时 ID ' has not been initialized. It has not been requested..."

我正在尝试使用SharePoint2013中的客户端对象模型访问库的ID。但出现错误:Thepropertyorfield'Id'hasnotbeeninitialized.Ithasnotbeenrequestedortherequesthasnotbeenexecuted.Itmayneedtobeexplicitlyrequested.下面是我的代码:varcontext=SP.ClientContext.get_current();varweb=context.get_web();varitems=SP.ListOperation.Selection.getSelectedIt

javascript - Jquery 未捕获类型错误 : Cannot read property 'replace' of undefined

任何人都可以告诉我为什么会出现此错误:未捕获的类型错误:无法读取未定义的属性“替换”functioncheckNewPost(x){varpid=$('#NewPostbody').attr('class');if(pid==='post-t'){setTimeout(checkNewPost,);}else{$.ajax({type:"POST",url:"/html_postReply.php",data:"pid="+pid.replace('post-t','')+"&type=1",success:function(html){if(html){$('.tekin').app

javascript - 类型错误 : Cannot read property 'push' of undefined -Express

我已经为使用express路由和创建服务器的nodejs应用程序编写了两个Javascript文件。由于我是初学者,我对此了解不多。当我运行该应用程序时,它向我显示以下错误:-/usr/lib/node_modules/express/lib/router/index.js:472this.stack.push(layer);^TypeError:Cannotreadproperty'push'ofundefinedatFunction.use(/usr/lib/node_modules/express/lib/router/index.js:472:15)atObject.(/hom

javascript - 未捕获的类型错误 : Cannot read property 'lat' of undefined when serializing leaflet data with $. 参数()

我想先说明一下:我是JavaScript的新手。我正在尝试使用Leaflet和AJAX调用发布用户位置和map边界。在我的事件处理程序stateUpdater.onLocationFound中,日志语句打印出正确的用户坐标和map边界,但是我在尝试时得到UncaughtTypeError:Cannotreadproperty'lat'ofundefined使用$.param()序列化这些值。我正在使用Leafletv0.7.2和jQuery1.11.0。varmap;$(document).ready(function(){map=newL.map('map').setView([41

javascript - findRecord 给出错误 "Cannot read property ' _internalModel' of undefined"

在我们的ember应用程序中,我们使用以下版本的ember-data和ember-data-factory-guy。包.json"ember-cli":"^1.13.8","ember-data":"1.13.9","ember-data-factory-guy":"1.13.10",注意:我们使用的是事件模型适配器,尚未迁移到json-api适配器。importActiveModelAdapterfrom'active-model-adapter';exportdefaultActiveModelAdapter.extend({路由:item.jsexportdefaultEmber

javascript - React/Redux 服务器端渲染中的警告 : Did not expect server HTML to contain a <li> in <ul>.

我是第一次使用React和Redux进行服务器端渲染,似乎遇到了一些困难。我收到警告:Warning:DidnotexpectserverHTMLtocontainain.我查了一下,这意味着html树不匹配。我不确定那是怎么回事。有没有明显的方法来解决它?这是我的代码,它会发出警告。importReact,{Component}from'react';import{connect}from'react-redux';importactionsfrom'../actions';classUsersListextendsComponent{componentDidMount(){if(t

javascript - babel-preset-env 语法错误 : Unexpected token with spread properties

为什么它不接受传播属性?为此,我正在使用babel-preset-env。.babelrc{"presets":["react",["env",{"targets":{},"debug":true,"modules":"commonjs"}]]}package.json{"name":"myapp","version":"0.1.0","main":"index.js","private":true,"dependencies":{"babel-core":"6.25.0","babel-loader":"7.1.1","babel-preset-env":"^1.6.0","babe

javascript - Selenium 网络驱动程序 : firefox headless inject javascript to modify browser property

我正在尝试弄清楚如何将seleniumwebdriver与python或java结合使用来注入(inject)javascript以修改浏览器属性/属性。我的最终目标是获得类似于this的东西使用selenium和firefox,因为它是更开放和灵活的选择。Puppeter和chromium文件test.js:constpuppeteer=require("puppeteer");(async()=>{constbrowser=awaitpuppeteer.launch({args:["--no-sandbox"],headless:true,});constpage=awaitbro