Displaying 20 results from an estimated 20000 matches similar to: "question regarding link_to vs link_to_remote"
2008 Jul 23
0
Link_to_remote object missing
Hello, I''m in troubles trying to use ''link_to_remote'' on Rails 2.1.
Having this page:
<h4>Editing project</h4>
<% form_for(:project, :url => project_path(@project), :html =>
{ :method => :put }) do |f| %>
<p>
Name <%= f.text_field :name %>
Date <%= calendar_date_select :project, :target_date, :time =>
2006 May 18
2
How to add hint to link_to_remote?
To add a hint to normal link is very easy:
link_to ''design'', {:action => ''design'', :id => survey}, :title =>
''Design the survey''
but, after trying several times, I still can''t figure out how to do the
same to link_to_remote. I''ve tried put :html => {:title => ''blah''}. It
doesn''t
2008 Jul 17
2
Problem with link_to_remote, RJS and jRails
Hi, everyone,
I''m trying to update the content of a div using link_to_remote and RJS
template.
Everything works fine if I use the default Prototype/Scriptaculous
libraries, but I want to use jRails ''coz other parts of my application
use a lot of jQuery.
Here are the steps I done:
1. inside StatesController.rb I defined the following action:
def update_view
# do nothing just
2009 Jul 28
4
RJS-Template and link_to_remote
Hi, I am quite new to rails and can''t use any rjs-templates.
The problem is, that he can''t use/find the methods in that template
e.g. ''page'' or ''replace_html''. I get an error message on these
methods.
Here''s what I got so far in my example:
Controller:
----
class AjaxTestController < ApplicationController
layout
2006 Aug 17
2
link_to_remote question
I''m using link_to_remote to call a method that deletes an item
<%= link_to_remote " [delete]", :url => { :controller => ''user_admin'',
:action => ''employee_type_delete'',
:id => employee_type.id
}
2006 Apr 19
2
how to pass a hash as a parameter in link_to_remote
When using link_to_remote, I''d like to pass along some auxiliary data in
the request. It''s a hash of dynamic data that can change with each
request.
But I get an error when rails trying to "stringify" the hash.
For the regular link_to, it works because it turns the hash into a
regular GET-like query string.
I''m expecting to be able to get my hash as
2008 Apr 13
3
Can't get simple link_to_remote to work
AFAICT, this is all I need to do to get a simple example working:
the <head> should have this:
<%= javascript_include_tag :defaults %>
My test page view should have a div with an id and the ERB like this:
<%= link_to_remote ''Click Me'',
:url => {:action => ''show_time'',
:update => ''time_box''} %>
2006 Apr 04
2
How to add CSS tips to link_to_remote?
The following code of tag clouds implementation:
<%= link_to(h("<#{tag}>"), "tags/listmytag/#{tag}", { :style =>
"font-size: #{font_size}" } ) -%>
I want to change it to ajax style:
<%= link_to_remote "<#{tag}>",
{ :url => { :controller => ''tags'', :action => ''listmytag'', :id =>
2006 May 23
0
html "class" attribute for "link_to_remote"
Hi,
now this should be easy, but for some reason I was not able to generate
a link with a "class" attribute using "link_to_remote".
I tried several different ways, including the one that worked for
"link_to", but so far no luck.
I have to admit that I am not 100% sure how to read the rDoc
documentation. If it says:
link_to_remote(name, options = {},
2006 Jan 17
2
link_to_remote() - can I post data with it???
can I post data with link_to_remote(),
link_to() has special option :post => true and viola
Thanks in advance
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060117/2a0a00af/attachment.html
2006 Mar 15
2
link_to_remote issue after upgrading to rails 1.0
Hi
I''ve only recently noticed my notebook was using an old version of rails
(0.13), and so upgraded it to 1.0 (this is on gentoo linux).
The upgrade has broken some previously working code, and I''ve not been
able to find a work-around.
Previously the following call:
<%= link_to_remote("some string",
:update =>
2012 Feb 29
4
how to use link_to with :remote=>true in rails 3.2.1
I m using Rails 3.2.1. how to use link_to with remote=>true
--------------------------------------------
My Method in Controller
def clickme
@clk = "you click me"
respond_to do |format|
format.js { render :layout=>false }
end
end
--------------------------------------------
My View
In my new.html.erb file
<%= link_to "click here",
2009 Jul 26
2
How knows my paths in link_to? If I do not defined.
Hello,
It´s my first post here. :)
I´l following the guide of Ruby, but I need to know how the Ruby knows
my path to other pages if I did not define anything, like this:
app/views/posts/index.html.erb:
<td><%= link_to ''Show'', post %></td>
<td><%= link_to ''Edit'', edit_post_path(post) %></td>
Other
2006 Jul 21
10
Using an image button for "link_to_remote"
All,
I want to do an AJAX request using a custom image button. I currently
have this as a standard button action using "button_to".
What I need is the button equivalent of "link_to_remote". Is there a
helper that I can use, or do I need to build it by hand?
I see button_to_function(), but that sets me up to call a Javascript
function, not post to a Rails action.
Or can
2006 Feb 16
4
newbie question regarding basic AJAX form verification
Hi,
I''m confused about how form verification with AJAX works. Let''s say I have a
''new.rhtml'' view that contains a form with two fields, and the form action is
''create''. Let''s assume that I also want to do some type of data validation on
one of the two fields via AJAX before I submit the form. But since I''ve
already
2008 Feb 01
1
problems with link_to_remote and send_file
Hi everyone,
I working on an app that at some point generates an xls report(charts,
summary lines, etc) and sends it to the user.
If i use link_to everything works fine; however when change to
link_to_remote so i can make an ajax call it doesn;t seam to work ( i
do not get the save/open dialog box)
def exp_to_excel_2003
@filepath = "#{RAILS_ROOT}/public/files/Metrics Report.xls"
2008 Jan 18
8
link_to problem
hi @ all
I create a new archiv.html.erb and a archiv method in the controller.
Now, I would like to link from index.html.erb to archiv.html.erb. I
tried to use <%= link_to ''archive'', archiv_xxx_path %> but it doesn''t
run.
It appears a error message "SyntaxError in xxx#index".
Does anyone know, how I can enhance this problem?
thanks a lot...
--
Posted
2011 Apr 28
0
link_to with :remote=>true and how about :before=> ?
Hey Guys,
Before Rails 3.0 I was to be able invoke some javascript before and
after an ajax call was made, like this:
link_to_remote "aLabel", url, :before=>$(''indicator'').show(),
:complete=>$(''indicator'').hide()
In Rails 3.0, I understand I need to use link_to and pass the parameter
:remote=>true. link_to however, doesn''t accept
2006 Mar 08
6
Difficulty with params hash and submit_to_remote
Hi,
Is there any trick to initializing the params hash via submit_to_remote()? I
have a form with two submit methods - the regular, non-AJAX method, and the
AJAX method. The regular method works like a champ. The submit_to_remote
invokes the correct controller, but the params hash is empty except for the
values for :action and :controller.
I''d show my code, but it''s on
2010 Jul 06
0
Rails 3: link_to :remote => true with spinner
How is this most efficiently done? link_to_remote is gone.
I am using jQuery and am wondering how I could bind beforeSend call back
with my link_to :remote => true call. So that I can use it to draw
spinner.
Sharkie
--
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