What's the best way to pass string value from View to Controller?

I need to pass a string value from view to controller besides the
form_remote_tag value...

What's the best way to do it?

Is it possible to pass a parameter in send_data method?

For instance, send_data( channel_info) ?

Currently, I have the code as follows... but I need to pass in the
string value to controller with chat_input value.

I can really figure out a clean way to do it.

Please let me know. Thanks~!

View code....


Thanks for you reply.

Actually, that's what I am doing right now. But I want to make the
information that is passed from view to controller invisible to user.

I acutally do have one more form_remote_tag field, which is

<%= text_field_tag :channel_info ,@channel, {:size=>20} %>

But doing it this way, it's visible and modifiable to and by user. (I
made diabled option turn on, then it wouldn't let me pass the value in

Any other idea or suggestion?



Thank you for your help.

I am obviously a newbie to rails and web programing community as

Again Thanks~!


Way back in HTML 2.0 they invented the hidden field tag:


In Rails it's called hidden_field or hidden_field_tag depending on
your form setup: