Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8042663
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T04:39:38+00:00 2026-06-05T04:39:38+00:00

When I am trying to call the collections.fetch method i am getting the following

  • 0

When I am trying to call the collections.fetch method i am getting the following error in console :

Uncaught TypeError: Object function (a){return new j(a)} has no method 'isObject' 

Here is my app.js :

 var Items = Backbone.Collection.extend({
    url : function() {
        return "names/all/" + this.pageStart + "-" + this.pageEnd;
    },
    pageStart : 1,
    pageEnd : 5
});

var ScrollView = Backbone.View.extend({
    el : $('#list'),
    initialize : function() {
        _.bindAll(this, 'getNames');
        this.collection.bind('all', this.addAll);
        this.collection.fetch(); //getting error coz of this line here.
    },
    getNames : function() {
        this.collection.fetch();
    },

    addAll : function() {
        alert(JSON.stringify(this.collection));
        this.collection.each(function(item) {
            alert(":");
            this.addOne(item);
        });
    },
    addOne : function(item) {
        alert(item);
    }
});
var coll = new Items();
var scrollView = new ScrollView({collection: coll});

Here is the scripts versions i am using

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js"></script>
<script src="http://ajax.cdnjs.com/ajax/libs/json2/20110223/json2.js"></script>
<script src="http://ajax.cdnjs.com/ajax/libs/underscore.js/1.1.6/underscore-min.js"></script>
<script src="http://ajax.cdnjs.com/ajax/libs/backbone.js/0.9.2/backbone-min.js"></script>

However the response i am getting from the server is OK 200 status
This is the respose i am getting

[{"firstName":"A","lastName":"last","id":"1"},{"firstName":"B","lastName":"last","id":"2"},{"firstName":"C","lastName":"last","id":"3"},{"firstName":"D","lastName":"last","id":"4"},{"firstName":"E","lastName":"last","id":"5"}]

And finally these are my response headers:

Request URL:http://localhost:8080/mongodb/names/all/1-5
Request Method:GET
Status Code:200 OK
Request Headersview source
Accept:application/json, text/javascript, */*; q=0.01
Accept-Charset:ISO-8859-1,utf-8;q=0.7,*;q=0.3
Accept-Encoding:gzip,deflate,sdch
Accept-Language:en-US,en;q=0.8
Cache-Control:max-age=0
Connection:keep-alive
Host:localhost:8080
Referer:http://localhost:8080/mongodb/
User-Agent:Mozilla/5.0 (Windows NT 5.1) AppleWebKit/536.5 (KHTML, like Gecko) Chrome/19.0.1084.52 Safari/536.5
X-Requested-With:XMLHttpRequest
Response Headersview source
Content-Type:application/json;charset=UTF-8
Date:Thu, 31 May 2012 17:32:10 GMT
Server:Apache-Coyote/1.1
Transfer-Encoding:chunked

Please help someone.
Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T04:39:40+00:00Added an answer on June 5, 2026 at 4:39 am

    You use underscore 1.1.6 with backbone 0.9.2 which requires underscore 1.3.1.

    See http://backbonejs.org/#upgrading

    Upgrading to 0.9

    If you’re upgrading, make sure you also upgrade your version of
    Underscore.js to the latest — 1.3.1 or greater.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to call the stored procedure using subsonic and getting Object Reference
I'm trying to call a Sort method that expects a parameter of type IComparer<object>
I am trying to call this method to concat two arrays using Google Collections
I'm trying to call a return type method from another class but I keep
I'm trying to call the HttpServerUtuility.URLDecode function in C# using Visual Studio 2005, but
I am trying to call Action method passing a single parameter. The method (Accepts
Scenario : Trying to call the .AttachAll method on a table in my LinqToSql
I'm trying to get image from web service and I'm getting an error. 'System.Web.UI.WebControls.Image'
I am trying to call a class method through reflection. public class A {
Trying to call a SAP SOAP Web Service from a generated sudzc app shows

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.