Error: jquery-ujs has already been loaded!Q2. I am using jquery autocomplete and i getting errorTypeError: $(...).autocomplete is not a functionQ3 When i include <%= javascript_include_tag :defaults %> i am getting error below one
Hi ,I am facing one problem , when i require //= require jquery_ujs in app.js than i am getting error in console.Q1. What is use jquery_ujs.js ?We have already included jquery.js than why we need jquery_ujs.js ?
########application.js####################//= require jquery//= require jquery-ui//= require jquery_ujs//= require_tree .
getting error in firebug console shown below:-Error: jquery-ujs has already been loaded!Q2. I am using jquery autocomplete and i getting errorTypeError: $(...).autocomplete is not a function
Q3 When i include <%= javascript_include_tag :defaults %> i am getting error below one"NetworkError: 404 Not Found - http://localhost:3000/assets/defaults.js"
--ThanksFahim Babar Patel
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonra...@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-ta...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/YwNCZ9-oKgsJ.
For more options, visit https://groups.google.com/groups/opt_out.
Sent from my iPhoneHi ,I am facing one problem , when i require //= require jquery_ujs in app.js than i am getting error in console.Q1. What is use jquery_ujs.js ?We have already included jquery.js than why we need jquery_ujs.js ?It is needed so that links that have remote: true and is not a get request will include the authenticity token when you click it. Search for jquery_ujs########application.js####################//= require jquery//= require jquery-ui//= require jquery_ujs//= require_tree .What gem provides jquery-ui? It may already be loading ujs. You can look at this gem of you want to use jquery uihttps://github.com/joliss/jquery-ui-rails
If you're having the error above, other js wont probably run.getting error in firebug console shown below:-Error: jquery-ujs has already been loaded!Q2. I am using jquery autocomplete and i getting errorTypeError: $(...).autocomplete is not a functionReplace :defaults with 'application'Q3 When i include <%= javascript_include_tag :defaults %> i am getting error below one"NetworkError: 404 Not Found - http://localhost:3000/assets/defaults.js"
On Tuesday, November 27, 2012 5:23:48 AM UTC+5:30, jim wrote:
Sent from my iPhoneHi ,I am facing one problem , when i require //= require jquery_ujs in app.js than i am getting error in console.Q1. What is use jquery_ujs.js ?We have already included jquery.js than why we need jquery_ujs.js ?It is needed so that links that have remote: true and is not a get request will include the authenticity token when you click it. Search for jquery_ujs########application.js####################//= require jquery//= require jquery-ui//= require jquery_ujs//= require_tree .What gem provides jquery-ui? It may already be loading ujs. You can look at this gem of you want to use jquery uihttps://github.com/joliss/jquery-ui-railsIn dummy project i do //= require jquery_ujs in app.js and there is no error message shown.
If you're having the error above, other js wont probably run.getting error in firebug console shown below:-Error: jquery-ujs has already been loaded!Q2. I am using jquery autocomplete and i getting errorTypeError: $(...).autocomplete is not a functionReplace :defaults with 'application'Q3 When i include <%= javascript_include_tag :defaults %> i am getting error below one"NetworkError: 404 Not Found - http://localhost:3000/assets/defaults.js"I include <%= javascript_include_tag :defaults %> in one of dummy project and there is no error is showing in console.Did i am missing any thing which create problem in javascript files?
To post to this group, send email to rubyonra...@googlegroups.com.--ThanksFahim Babar Patel
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group, send email to rubyonrails-ta...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/YwNCZ9-oKgsJ.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonra...@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-ta...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/6SDefAelKkgJ.
On Tue, Nov 27, 2012 at 12:56 PM, Fahim Patel <paf...@gmail.com> wrote:
On Tuesday, November 27, 2012 5:23:48 AM UTC+5:30, jim wrote:
Sent from my iPhoneHi ,I am facing one problem , when i require //= require jquery_ujs in app.js than i am getting error in console.Q1. What is use jquery_ujs.js ?We have already included jquery.js than why we need jquery_ujs.js ?It is needed so that links that have remote: true and is not a get request will include the authenticity token when you click it. Search for jquery_ujs########application.js####################//= require jquery//= require jquery-ui//= require jquery_ujs//= require_tree .What gem provides jquery-ui? It may already be loading ujs. You can look at this gem of you want to use jquery uihttps://github.com/joliss/jquery-ui-railsIn dummy project i do //= require jquery_ujs in app.js and there is no error message shown.In this case, I'm not sure what's wrong. when you say app.js, do you mean application.js? Or doyou have another js file by the name of app.js?
If you're having the error above, other js wont probably run.getting error in firebug console shown below:-Error: jquery-ujs has already been loaded!Q2. I am using jquery autocomplete and i getting errorTypeError: $(...).autocomplete is not a functionReplace :defaults with 'application'Q3 When i include <%= javascript_include_tag :defaults %> i am getting error below one"NetworkError: 404 Not Found - http://localhost:3000/assets/defaults.js"I include <%= javascript_include_tag :defaults %> in one of dummy project and there is no error is showing in console.Did i am missing any thing which create problem in javascript files?I'm also not sure about this one. Newly generated projects dont use the :default directive (do you call it a directive?).They use 'application' which is the reason why I told you to change it to 'application' because it is trying to load default.js
NetworkError: 404 Not Found - http://localhost:3000/assets/defaults.js"