# Problem with parameters

**URL:** <https://www.ruby-forum.com/t/problem-with-parameters/155496>\
**Category:** Ruby\
**Created:** [December 12, 2008, 2:47pm UTC](https://www.ruby-forum.com/t/problem-with-parameters/155496 "2008-12-12T14:47:12Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![chimorito](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/54ee81/32.png) [@chimorito](https://www.ruby-forum.com/u/chimorito)\
**Post date:** [December 12, 2008, 2:47pm UTC](https://www.ruby-forum.com/t/problem-with-parameters/155496/1 "2008-12-12T14:47:12Z")

</div>

First at all sorry if my english is not the best.

In the view I have this code:

\<%= select\_tag “tabla”, options\_for\_select([“Famitel”, “Polycom Kirk”,  
“LG Nortel”, “Dimax Videovigilancia”]) %\>  
\<%= text\_field :buscar, params[:codigo\_aleatorio]%\>  
\<%= button\_to “Buscar” , :action =\> :elijovista %\>

In elijovistaÂ´s controller I need to know the item that was selected in  
tabla and the text.

my code is:  
def elijovista  
debugger  
return params[:payment]

```
case :tabla
    when "Famitel"
     @ticket=Ticket.find( :first, :select =>"reference",

```

:conditions=\>[‘codigo\_aleatorio=?’,params[:codigo\_aleatorio]])

```
    # renders app/views/zonaclientes/showFamitel
    render :template => 'zonaclientes/showFamitel'
  return

```

.  
.  
.  
.  
(The same for the rest of the items)  
.  
.  
But render never works, always show the elijovista view.

Whats wrong? How can obtain the option selected in tabla?

Thanks for all

---

<div class="post-metadata">

**Author:** ![chimorito](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/54ee81/32.png) [@chimorito](https://www.ruby-forum.com/u/chimorito)\
**Post date:** [December 12, 2008, 3:43pm UTC](https://www.ruby-forum.com/t/problem-with-parameters/155496/2 "2008-12-12T15:43:54Z")

</div>

thanks

---

<div class="post-metadata">

**Author:** ![chimorito](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/54ee81/32.png) [@chimorito](https://www.ruby-forum.com/u/chimorito)\
**Post date:** [December 12, 2008, 3:17pm UTC](https://www.ruby-forum.com/t/problem-with-parameters/155496/3 "2008-12-12T15:17:43Z")

</div>

> Whats wrong? How can obtain the option selected in tabla?

You might get better answers in a Rails-specific forum :

[http://groups.google.com/group/rubyonrails-talk](http://groups.google.com/group/rubyonrails-talk)  
[http://railsforum.com/](http://railsforum.com/)

Good luck,

Chris
