similar to: Problems with AJAX and bind

Displaying 20 results from an estimated 80000 matches similar to: "Problems with AJAX and bind"

2011 Jul 27
20
Rails, jquery and Ajax
How do I make an ajax call and then update a div with a partial? I''ve tried this but it''s not working. Comment is created but the partial is not loaded. //view <a href="#" id="testlink">Testlink</a> <div id="commentlist"> </div> //controller def new @comment = Comment.new @comment.save
2010 Apr 09
2
dynamically linking to ajax.googleapis jquery
Hi I am using jquery and jqueryui in my application And in layout I use <%= javascript_include_tag "http://ajax.googleapis.com/ajax/libs/jquery/1.4.1/jquery.min.js"%> <%= javascript_include_tag "http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js" %> <%= stylesheet_link_tag
2013 Mar 11
8
Access instance variable in ajax rendered by controller - Rails
I am making an ajax call to my controller. Controller is sending in the response in an instance variable(as a json object). How can I access the same in my ajax javascript? This is my ajax call code: $(document).ready(function(){ var currentCellText; $(".inline").click(function() { currentCellText = $(this).text(); $.ajax({ type: ''GET'', dataType: "json",
2010 Mar 09
9
Ajax-submit form on "check box onclick ": why this error?
Hi there, I need to have a checkbox which ajax-submits a form. The following code throws an error "index 112009 out of string". What''s wrong here? ============================================== <% form_remote_tag :url => { whatever_url } do -%> <%= check_box_tag ''whatever'', nil, whatever, { :onclick =>
2011 Dec 17
7
How to fire Ajax call from Form_for
I am learning Rails 3 and need some help on Ajax part. I am trying to accomplish the following: There is a textarea on the page which has a length of letters constraint, say 100. Every time a symbol is typed there,a nearby label tells you how many letters you have left. I plan to use Ajax to do this. I googled for a few hours and could not figure out how to do this. So far what I have done is
2010 Jun 08
8
rails, ajax, json, and script
Could someone please demonstrate the code to send both json (or xml) AND javascript (to be executed) in a single Ajax request? Is this even possible? -- Posted via http://www.ruby-forum.com/. -- 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
2010 Feb 25
10
ajax.updater problem
Hi everyone I´know that it is not a ajax forum, but Im using ajax ina program created with rails code and I think that I´m not the unique person who use the Ajax. UpdaterPeriodically. My problem is that my program doesn´t refresh the div tag, following it´s my source code. Anyone can say me why it doesn´t work? <head> <%= javascript_include_tag ''prototype'' %>
2013 May 27
6
Headache with Ajax in Rails using jQuery
Hello everyone, I''m a newbie at Ruby on Rails. I spent nearly two days of the Memorial Day weekend stumbling upon making Ajax working in Rails. At this point, I''m so exhausted and hope that I can get some help to move forward. I have tried nearly everything I found on Google but still not successful. Initially, I tried the Ajax approach offered by Rails but did not work, so I
2010 Jun 02
1
Ajax with JQuery
I have used Ajax link and live validation in index.rhtml Ajax link requires JavaScript "prototype" and live validation requires "jquery". i got "element.dispatchEvent is not a function" on the firebug console when i used "prototype" and "jquery" in same page index.rhtml after i removed javascript "prototype" library, i got "Ajax is
2011 Sep 07
4
jquery and ajax query in rails 3
hi people I don''t know much about ajax - jquery. And right now I need to use some functionality with them. In a form (sales model) I have the following code: <div> <%= f.label :product_id, "Product" %> <%= f.collection_select( :product_id, Product.all, :id, :name, options={} ) %> </div> <div> <%= f.label :price,
2010 Jun 28
2
jquery ajax.submit() help
Hi all, I need some quick help in jquery. While using jquery ajax.Submit(), we can specify the target div to be modified with the template rendered by the corresponding action. Is there way using which we can update multiple divs ( using render update) from the called action in ajax.submit() I am stuck and for now i am populating a complete page again but its incorrect. I need to update
2010 Sep 21
7
Ajax CSRF in Rails3
I''m using rails3. It does not seem to check the authenticity_token when doing a POST using Ajax. I traced this to: module ActionDispatch class Request < Rack::Request ..... def forgery_whitelisted? get? || xhr? || content_mime_type.nil? || ! content_mime_type.verify_request? end end so you don''t check if its a get? or a xhr? (ie ajax request). Is this correct? --
2012 Jan 24
2
How would you do this in ajax in rails 3
I have a rails 3.1 app and I am curious how you would do something. I have a link_to remote option true button <%=link_to "Add to your Favorites", add_favorite_url(movie_star),:class=>"btn small primary" %> I need to submit this to the users controller via ajax do some stuff then set the button to say that the favorite has been added. Can you please tell me how
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 Aug 07
4
how to do render partial on jquery ajax success method with rails 3
I''m using rails 3.2.1 with jquery for an ajax call. My juqery code is : jQuery.ajax({ url: "/org_pages", data: ''org_id=''+ org_id, type: "POST", success: function(result){ jQuery("#image_center").html("<%= escape_javascript(render(:partial =>
2012 Oct 26
7
How to use Ajax with rails ?
Hi all, Can any one tell me how to use Ajax with Rails. Send me quick start up link and videos. Thanks Regards Fahim 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this
2013 Jun 26
2
having isues with creating a ajax call in my simple rails application ,
hi all , having isues with creating a ajax call in my simple rails application , can any body be available for some time to help on mail or chat ?? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to
2011 May 17
2
HTML snapshots for crawlable ajax
Hi, There doesn''t seem to be any reference for taking HTML snapshots from within a Rails server. I wonder how one could implement Google''s crawlable AJAX spec (http://code.google.com/web/ajaxcrawling/docs/learn-more.html)on a Rails application? To summarize: I have a Rails application with a Javascript front-end with lots of AJAX. I need Google to index the AJAX content, hence
2010 Jul 30
2
:disable_with combined with Ajax form: Possible?
Hi there, I''m trying to have an Ajax form with a submit button that has the :disable_with feature, but the submit button does *not* disable... I tried like this: = = = <% form_remote_tag :url => { :controller => ''profiles'', :action => ''update'' }, :method => :put do -%> <%= submit_tag ''Save'', :disable_with
2013 Jan 09
4
CSRF resets my session in Firefox
Hello all, I''ve been trying to diagnose an issue with CSRF and Firefox specifically. I''ve got an ajax based form, using UJS (yes, I have csrf_meta_tag in my layout and I''ve tried adding the X-CSRF-Token header to the ajax beforeSend events without any luck)... The form just posts some data to an ajax method that creates, saves, and sets the session for a shopper as