# Link\_to\_remote, doesn't receives params?

**URL:** <https://www.ruby-forum.com/t/link-to-remote-doesnt-receives-params/75381>\
**Category:** Rails\
**Created:** [March 1, 2006, 8:00pm UTC](https://www.ruby-forum.com/t/link-to-remote-doesnt-receives-params/75381 "2006-03-01T20:00:11Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![sayoyo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/ba8739/32.png) [@sayoyo](https://www.ruby-forum.com/u/sayoyo)\
**Post date:** [March 1, 2006, 8:00pm UTC](https://www.ruby-forum.com/t/link-to-remote-doesnt-receives-params/75381/1 "2006-03-01T20:00:11Z")

</div>

Hi,

I’m using link\_to\_remote to trigger an ajax zone, but  
depends on a varaible, the new zone has different  
features. before I has a button inside a form. so when  
I click on the button, I get the value of the variable  
inside “params”. but since I use link\_to\_remote now, I  
don’t get any value from params anymore… Is there  
some way I can get the data inside a form with  
link\_to\_remote function???

Thanks you very much

Saiho

* * *

Do You Yahoo!?  
Tired of spam? Yahoo! Mail has the best spam protection around

> **[Yahoo Mail - Organized Email](https://mail.yahoo.com/)**
>
> It's time to get stuff done with Yahoo Mail. Just add your Gmail, Outlook, AOL or Yahoo Mail to get going. We automatically organize all the things life throws at you, like receipts and attachments, so you can find what you need fast. Plus, we've got...

---

<div class="post-metadata">

**Author:** ![sayoyo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/ba8739/32.png) [@sayoyo](https://www.ruby-forum.com/u/sayoyo)\
**Post date:** [March 1, 2006, 8:08pm UTC](https://www.ruby-forum.com/t/link-to-remote-doesnt-receives-params/75381/2 "2006-03-01T20:08:39Z")

</div>

See parameter :with of link\_to\_param function. You could pass any valid  
Javascript function  
i.e. :with=\>"‘value’+$F(‘whatever’)"

---

<div class="post-metadata">

**Author:** ![sayoyo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/ba8739/32.png) [@sayoyo](https://www.ruby-forum.com/u/sayoyo)\
**Post date:** [March 1, 2006, 8:35pm UTC](https://www.ruby-forum.com/t/link-to-remote-doesnt-receives-params/75381/3 "2006-03-01T20:35:12Z")

</div>

Hi, thanks you very much for thew information, but I  
don’t really understand where I should start, I looked  
for a function “link\_to\_param” in rails api, but I  
didn’t find it… can you tell me where I should  
go???

Thanks you very much!!!

— Anatol P. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> but
> 
> > link\_to\_remote function???
> > 
> > * * *
> > 
> > * * *
> 
> Rails mailing list  
> removed\_email\_address@domain.invalid  
> [http://lists.rubyonrails.org/mailman/listinfo/rails](http://lists.rubyonrails.org/mailman/listinfo/rails)

* * *

Do You Yahoo!?  
Tired of spam? Yahoo! Mail has the best spam protection around

> **[\[object](https://mail.yahoo.com/)**
>
> \[object

---

<div class="post-metadata">

**Author:** ![sayoyo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/ba8739/32.png) [@sayoyo](https://www.ruby-forum.com/u/sayoyo)\
**Post date:** [March 2, 2006, 2:21am UTC](https://www.ruby-forum.com/t/link-to-remote-doesnt-receives-params/75381/4 "2006-03-02T02:21:33Z")

</div>

Hi, Saiho.

Sorry, I made a typo. Of course link\_to\_remote  
And :with param you pass any additional parameter that you want to send  
to  
server. So if you have some element (for example button) and you would  
like  
to pass value of this element then you could do it with following  
snippet

link\_to\_remote(… :with=\>"‘some\_param\_name’ + $F(‘some\_element\_id’)")

I hope that it is exactly you’ve asked.

---

<div class="post-metadata">

**Author:** ![sayoyo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/ba8739/32.png) [@sayoyo](https://www.ruby-forum.com/u/sayoyo)\
**Post date:** [January 17, 2007, 7:54pm UTC](https://www.ruby-forum.com/t/link-to-remote-doesnt-receives-params/75381/5 "2007-01-17T19:54:58Z")

</div>

Anatol P. wrote:

> Hi, Saiho.
> 
> Sorry, I made a typo. Of course link\_to\_remote  
> And :with param you pass any additional parameter that you want to send  
> to  
> server. So if you have some element (for example button) and you would  
> like  
> to pass value of this element then you could do it with following  
> snippet
> 
> link\_to\_remote(… :with=\>"‘some\_param\_name’ + $F(‘some\_element\_id’)")
> 
> I hope that it is exactly you’ve asked.

How do i pass another value into the :with, im trying to do a date from  
and date to search? now i can only pass one value.
