RailsCasts Pro episodes are now free!

Learn more or hide this

James R Qualls's Profile

GitHub User: sourcec0de

Site: http://facebook.com/qualls.james

Comments by James R Qualls

Avatar

Everyone just a note.... In some of the firefox browsers the headers get passed as HTML.

To fix this Ajax issue just respond_with :json, :html

Avatar

Solved my own problem, i did not realize that the router acts like a controller and where i called

ruby
new Ifoundit.Routers.Entries()

I should have put the name of my router

ruby
new Ifoundit.Routers.Posts()
Avatar

I am still having the same issue as stated above

ruby
(function() {

  window.Ifoundit = {
    Models: {},
    Collections: {},
    Views: {},
    Routers: {},
    init: function() {
      new Ifoundit.Routers.Entries();
Uncaught TypeError: undefined is not a function
      return Backbone.history.start();
    }
  };

  $(document).ready(function() {
    return Ifoundit.init();
  });

}).call(this);

I have set everything to the book, and restarted server several times, any ideas

ruby
//= require jquery
//= require jquery_ujs
//= require underscore
//= require backbone
//= require .//ifoundit
//= require_tree ../templates/
//= require_tree .//models
//= require_tree .//collections
//= require_tree .//views
//= require_tree .//routers
//= require_tree .
ruby
window.Ifoundit =
        Models: {}
        Collections: {}
        Views: {}
        Routers: {}
        init: ->
                new Ifoundit.Routers.Entries()
                Backbone.history.start()
$(document).ready ->
        Ifoundit.init()
Avatar

The repository they have them in does not have the newest version of underscore.

go to the gems location

Ruby1.9.3\lib\ruby\gems\1.9.1\gems\backbone-on-rails-0.9.2.0\vendor\assets\javascripts

replace the underscore.js file with your new one