similar to: trouble using jQuery in Rails 3.0.7

Displaying 20 results from an estimated 2000 matches similar to: "trouble using jQuery in Rails 3.0.7"

2012 Jan 01
3
'require_tree .' does not seem to be including the available *.js files as expected. Why?
Hi, all, Happy new year :) Referring to http://guides.rubyonrails.org/asset_pipeline.html, it seems that ''require_tree .'' in myapp/app/assets/javascripts/ application.js will include all *.js files in the myapp/app/assets/ javascripts/. I have a few other *.js files in this directory : parts.js, makes.js and categories.js. Here''s an extract from the html file I
2012 Nov 02
2
jquery error in production precompiled
In my rails project, for production precompile I do : rake assets:precompile RAILS_ENV=production But it not work for jquery. In my firegub console, I got the error “ReferenceError: JQuery is not defined “ at production.rb # Disable Rails''s static asset server (Apache or nginx will already do this) config.serve_static_assets = true # Compress JavaScripts and CSS
2010 Sep 09
0
Rails3: jquery-rails gem sets 'config.action_view.javascript_expansions' but cannot be overriden in 'config/application.rb'
Hello, I''ve created a new Rails3 app and I''m using jQuery instead of prototype. Gemfile: gem ''jquery-rails'' in my config/application.rb I want do the following: config/application.rb if Rails.env.production? config.action_view.javascript_expansions[:defaults] = %w(jquery.min rails application) else
2011 Jul 07
2
Rails 3.1 + jQuery + jQuery UI = data is null
Trying to get jQuery UI to work with my rails 3.1 setup, but i keep getting errors that i cant see posted anywhere, this is driving my insane so please have a look => [application.js] // This is a manifest file that''ll be compiled into including all the files listed below. // Add new JavaScript/Coffee code in separate files in this directory and they''ll automatically // be
2014 Apr 26
0
jquery_ujs.js 404
I am getting this annoying error which relates to jquery_ujs.js not being served. Any clues? This is the site link: http://test.kopy.com.br/home/index GET http://test.kopy.com.br/assets/jquery_ujs.js?body=1 404 (Not Found) index:11 GET http://ads.panoramtech.net/loader.js?client=tac net::ERR_BLOCKED_BY_CLIENT rev.js:4 Error in event handler for (unknown): Cannot read property 'state' of
2007 Mar 19
3
jQuery Users...
Any jQuery users out there? I would like to learn more about incorporating jQuery with Rails as the performance seems to be the best of any library I''ve seen and it is great in separating the JScript from the HTML. Any suggestions on where to get started? I''ve read this (http://b.lesseverything.com/2006/12/31/making-jquery-and- prototype-play-nice-in-rails) but was looking into
2011 Sep 06
8
Ajax and rails 3 UJS (jquery)
Hi, guys, I''m in the midst of moving an app from rails 2.3.8 to rails 3.0.9. Sadly, rails 3 no longer has javascript generators and I''m now forced to do more javascript. For my project, I have selected jQuery as the javascript framework for my rails 3.0.9 app. What I have done to have my app''s deletion link (for each item) trigger an alert box when the deletion
2012 Feb 26
0
Served asset /application.css - 304 Not Modified
Hi I am thinking to hide warning that is ”Served asset /application.css - 304 Not Modified”. How can I fix something if I change the settings? I''ve run that is less than server: rails new myapp cd myapp rake db:migrate rails s client: http://localhost:3000/books warning: Started GET "/assets/books.css?body=1" for 127.0.0.1 at 2012-02-26 14:48:35 +0900 Served asset /books.css
2012 Mar 07
1
link_to with :remote=>true works when bound to "click" but not "ajax:beforeSend"
Hi. I am trying to do an ajax link in Rails 3.2.1 and jQuery. I am loading jquery.js and jquery_ujs.js. In my document ready, if I bind to the event "click," clicking the link fires an event, but if I click to ajax:beforeSend, it doesn''t. Nothing happens when you click the link in JQuery. The event does go to the controller, though. Works: $(document).ready(function(){
2012 Jun 28
2
Best practice on Javascript and rails
Hi, I get constantly nervy whenever trying to implement any javascript / jquery in rails, basically because I''m not sure where to put things in the project! I know the people at rails have thought long and hard about how to best structure an app, so I''d like to learn the correct way. I''m using rails 3.2, ruby 1.9.3 ///////////// 1st situation - using a gem to include
2010 Sep 04
0
CSRF protection not working with jquery ajax post request
Hallo, I want to test the csrf protection of my application but forgery protection is not working with jquery ajax request. I have used Unobtrusive Javascript with jquery I have removed the <%= csrf_meta_tag %> so that my application do not include authenticity token. In my view I have the following code $(function () { $(''#alert'').click(function () { $.ajax({
2011 Jul 19
3
What does "require tree" do in Rails 3.1?
In Rails 3.1.... This is my application.css: /* *= require_self *= require_tree . */ This is my application.js: //= require jquery //= require jquery_ujs //= require jquery-ui //= require_tree . What does the "require_tree ." do? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To view this discussion on the web
2011 Sep 01
7
couldn't find file 'jquery' rails 3.1 stable mountable engine
When I create a new engine in Rails 3.1 stable and then access the dummy app or the engine I get an error say that the app can''t find jquery. I''ve created the engine using rails plugin new coffee --mountable I''ve also created a basic controller in the engine and the dummy app. If I remove the javascript include tag, everything works. But with the tag there it just
2010 Jun 16
4
firebug jQuery undefined message in rails app
In rails app, I add the following line of code in application.js and I get jQuery is not defined in firebug console. In application.html.erb, I have the following: <script type="text/javascript" src="../javascripts/application.js"></script> <script type="text/javascript" src="../javascripts/jquery-1.4.2.js"></script> and I installed
2011 May 25
0
Issues implementing jquery-form plugin for displaying image via an ajax call in my rails poc
Hello all, I am trying to implement a POC wherein I can post a message + image and get the same working via AJAX to display them both for each new entry without the page reloading. I am using a config of Ruby 1.8.7 and Rails 2.0.2 for project specific purposes.. I am also using a pretty old paperclip commit from github for this....I had to suit my proj config requirements mentioned previously..
2012 May 10
1
getting started with jQuery rails 3.2
Hi all, I''m trying to work out how to get started using some jQuery in my rails app. rails -v = 3.2.2 ruby -v = 1.9.3-p194 I''m only sporadically a web-developer, and still quite inexperienced with jQuery especially, so I may be making an obvious mistake. Essentially, I''ve done very little after creating a new app, I''ve learnt that jQuery is included by
2014 Apr 29
0
Bootstrap 3.1.1 is showing as BS 2...
I should first mention that I'm new to rails, but I updated to Ubuntu 14 today and I cloned my latest project from Github after installation. Everything seems to be working just as my last push, however my project is styled with Bootstrap 2... *but it should be 3.1.1.* I am not using the direct files in the stylesheets folder, instead I created my own custom.css.scss and did @import
2013 Jul 10
0
ActionView::Template::Error Not a directory vendor/assets/javascripts/ production
Hello, In production environment, I have this error ActionView::Template::Error Not a directory vendor/assets/javascripts/holder.js when in my template I have this line <%= image_tag "holder.js/150x200" %> My production.rb is : Libapp::Application.configure do # Settings specified here will take precedence over those in config/application.rb # Code is not reloaded
2012 Apr 15
5
JQuery-rails gem spec removal
Hi there, I don''t know if this is the right place to discuss such a topic. I''ve suggested to remove jquery-rails spec folder, since it hasn''t got any tests, they are not adapted to RSpec2 and not even to latest rails. They are one year old and it contains only one empty test. I have an application that runs all tests on all engines, being jquery-rails one of them. I
2011 Sep 19
1
Rails and UJS guide - not having much luck
I refered to http://railsdog.com/blog/2011/02/28/callbacks-in-jquery-ujs-in-rails3/ in hope of getting json data from my controller and displaying it in my view when an ajax request is made. I followed the instructions on the http://railsdog.com/blog/2011/02/28/callbacks-in-jquery-ujs-in-rails3/ and even corresponded with the author and also implemented his ''fix'' in