{"id":1930,"date":"2022-08-30T15:20:38","date_gmt":"2022-08-30T15:20:38","guid":{"rendered":"https:\/\/unknownerror.org\/index.php\/2013\/12\/04\/knockout-jsview-the-original-page-collection-of-common-programming-errors\/"},"modified":"2022-08-30T15:20:38","modified_gmt":"2022-08-30T15:20:38","slug":"knockout-jsview-the-original-page-collection-of-common-programming-errors","status":"publish","type":"post","link":"https:\/\/unknownerror.org\/index.php\/2022\/08\/30\/knockout-jsview-the-original-page-collection-of-common-programming-errors\/","title":{"rendered":"knockout.jsView the original page-Collection of common programming errors"},"content":{"rendered":"<h3>UnKnown Error<\/h3>\n<ul>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/39973c34030d0abf9e9c54339f58ad4b?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nSimone Vitale<br \/>\nasp.net-mvc knockout.js knockout-2.0 2013-12-4 5:05:20<br \/>\nI&#8217;m going crazy with knockuoutjs and binding:I have defined a CreateEditGroup.js document and I have created methods and Collection to retrieve or update a Group in my application:var url = window.location.pathname; var GroupID = url.substring(url.lastIndexOf(&#8216;\/&#8217;) + 1);var Group = function (group) {var self = this;self.GroupID = ko.observable(group ? group.GroupID : 0).extend({ required: true });self.Name = ko.observable(group ? group.Name : &#8221;).extend({ required: true }); };var GroupCollection<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/8690a24a66b76248edf490615a0c062a?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nGeorgesC<br \/>\njson knockout.js asp.net-mvc-4 asp.net-web-api runtime-error 2013-12-2 7:23:14<br \/>\nHy, I&#8217;m stuck with this error message and I can not find an solution.I get this message error in the Knockout JavaScript library v2.2.0:Unhandled exception at line 1053, column 5 inlocalhost:port\/Scripts\/knockout-2.2.0.debug.js 0x800a138f -Microsoft JScript runtime error: Invalid operand to &#8216;in&#8217;: Objectexpected If there is a handler for this exception, the program may besafely continued.It stops at this line of code in knockout-2.2.0.debug.jsif ((initialValues !== null) &amp;&amp; (initialValues<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/804eb78b5648b152702b8cdfbba8b3f5?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nRay Cheng<br \/>\njavascript asp.net-mvc asp.net-mvc-4 knockout.js internet-explorer-8 2013-11-28 15:09:30<br \/>\nThis is the error message when IE8 crashes.Unhandled exception at 0x05A99E34 (mshtml.dll) in iexplore.exe: 0xC0000005: Access violation reading location 0x0000003C.the following works.&lt;tbody data-bind=&#8221;foreach: searchResults&#8221;&gt;&lt;tr&gt;&lt;td data-bind=&#8221;text: orgName&#8221;&gt;&lt;\/td&gt;&lt;\/tr&gt; &lt;\/tbody&gt;but the following crash on IE8 (works on IE10, FF and Chrome).orgName is just a string set in the vm.searchStakeholder.Here&#8217;s more about the view model.var Stakeholder = (function () {f<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/3a0e9f81e3f850ad900ad132f9bce180?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\ndejobo<br \/>\nasp.net-mvc knockout.js single-page-application durandal hottowel 2013-11-27 21:14:42<br \/>\nI am using the upgraded version of Hot Towel template which has new versions of Durandal, Knockout, Breeze, etc. for a Single Page Application. This process works fine with the older version but not the newest.This is the error I get:Unhandled exception at line 93, column 13 in [http:\/\/servername:50921\/Scripts\/durandal\/viewEngine.js]0x800a138f &#8211; Microsoft JScript runtime error: Unable to get value of the property &#8216;length&#8217;: object is null or undefinedI have changed the convention for the viewLoca<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/45dad4148d98d78c5539eeefc39baa5e?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nuser1648962<br \/>\nknockout.js knockout-mapping-plugin appframework 2013-11-16 10:53:39<br \/>\nI am developing an appframework based mobile application using knockout js for data binding. I keep getting the following error message on my browser console :Uncaught Error: Unable to parse bindings. Message: ReferenceError: technology_name is not defined; Bindings value: text: technology_name, click: $parent.loadSubSection I can verify that the data is loaded but the knockout binding doesn&#8217;t seem to work properly. Could anyone please help me out ?. My code is like follows :Index.html&lt;!DOCT<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/2f880d3f794cec5ce1d7729f02faafee?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\njmogera<br \/>\njquery asp.net-mvc-3 jquery-ajax knockout.js 2013-11-15 19:38:23<br \/>\nA public action method &#8216;AddPromoCode&#8217; was not found on controller&#8217;Flazingo.Controllers.PositionController&#8217;. atSystem.Web.Mvc.Controller.HandleUnknownAction(String actionName) atSystem.Web.Mvc.Controller.ExecuteCore() atSystem.Web.Mvc.ControllerBase.Execute(RequestContext requestContext)atSystem.Web.Mvc.MvcHandler.&lt;&gt;c_DisplayClass6.&lt;&gt;c_DisplayClassb.b_5()at System.Web.Mvc.Async.AsyncResultWrapper.&lt;&gt;c_DisplayClass1.b_0()at System.Web.Mvc.MvcHandler.&lt;&gt;c_DisplayClasse.b__d() atSystem.Web<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/ed714bbd8c4249a0f337c78fbfb3ac1a?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nfatman<br \/>\njavascript knockout.js requirejs knockout-2.0 2013-11-15 18:43:57<br \/>\nI&#8217;m trying to debug ko (version: 2.2.1) using &lt;pre&gt; tag:&lt;pre data-bind=&#8221;text:ko.toJSON($root,null,2)&#8221;&gt;&lt;\/pre&gt;but I&#8217;m getting this:Uncaught Error: Unable to parse bindings. Message: TypeError: Object object has no method &#8216;getType&#8217;; Bindings value: text:ko.toJSON($root,null,2) UPDATE:It seems like the $root object is actually the windows object, why is it happening, how can i make sure it remains in the scope of my ViewModel?The scenario is like this:I have a view that contains al<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/de55e4a144182fd7f08e929cffe3f9fa?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nrelatively_slow<br \/>\njquery visual-studio knockout.js jqplot 2013-11-15 16:42:40<br \/>\nI am working on a web app, and I very much like the drag graphs that JQPlot offers. I am referring to this example on their site: http:\/\/www.jqplot.com\/deploy\/dist\/examples\/customHighlighterCursorTrendline.htmlAs I understand, to get JQPlot working, I need to include Jquery, the jquery jqplot fucntion, and a couple of styling files. The JQPlot download provides its own jquery.js and jquery.jqplot.js. Additionally, I am also using Knockout.js as part of this project, and I am including the stand<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/edae4887d64a89e85d9bcad988103654?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nOzi<br \/>\nknockout.js knockout-mapping-plugin 2013-11-15 16:37:49<br \/>\nI&#8217;m relatively new to Knockoutjs and trying implement some advanced filtering. I&#8217;m looking to filter my viewmodel data using multiple categories using a series of checkboxes. I&#8217;ve followed a number of solutions which allow filtering based on one criteria\/category at a time. However, I&#8217;ve been unable to get the advanced filtering working. Problem occurs when i&#8217;m filtering based on values in the nested array. e.g. education.course. Appears to work fine where the selected course corresponds to an o<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/2ca3642203e4f8e02b23f8657886315e?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nKasper Lewau<br \/>\njavascript jquery mvvm knockout.js knockout-sortable 2013-11-15 16:04:14<br \/>\nWhat I&#8217;m trying to achieve: A form with one text input field(Name), two select fields with some options(Type &amp; Column) with a submit button that creates a Widget with it&#8217;s title set to Name, data-type set to Type and Column &#8211; being it&#8217;s position in the page. Type in this case has a couple of different options defined in the view, it works just dandy so I won&#8217;t go into how I got that working, for now. As of now I have a page with three columns, each as it&#8217;s own observableArray &#8211; like so: sel<\/li>\n<\/ul>\n<p id=\"rop\"><small>Originally posted 2013-12-04 00:39:20. <\/small><\/p>","protected":false},"excerpt":{"rendered":"<p>UnKnown Error Simone Vitale asp.net-mvc knockout.js knockout-2.0 2013-12-4 5:05:20 I&#8217;m going crazy with knockuoutjs and binding:I have defined a CreateEditGroup.js document and I have created methods and Collection to retrieve or update a Group in my application:var url = window.location.pathname; var GroupID = url.substring(url.lastIndexOf(&#8216;\/&#8217;) + 1);var Group = function (group) {var self = this;self.GroupID = [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-1930","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/1930","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/comments?post=1930"}],"version-history":[{"count":0,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/1930\/revisions"}],"wp:attachment":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/media?parent=1930"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/categories?post=1930"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/tags?post=1930"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}