[Facebooker-talk] javascript help

Joseph Durden josephdurden at gmail.com
Wed Nov 12 19:56:02 EST 2008


First off, I have no experience with javascript.

Below is the html from an input submit.  I am having problems in my
controller with params[:ids] being set when it should not be getting
set when clicking the input type submit value="Next".  This
params[:ids] should only be set when clicking the input type
value="Send Message".
The problem exists when selecting a list of users, and then removing
them from the selection before submitting.  If this is the html that
is in a
facebook canvas page, how could I write javascript that sets the
parameters of the form to be empty, so that the parameters set
params[:ids] in the controller to
nil if the input submit value="Next" is clicked?  I figure I could do
a check in two ways: one by checking the value of the input type being
submitted,
and if the value is Next, set the parameters to empty,and the other by
checking the name of the input type, and if there is no name, then set
parameters to empty.
How would I approach getting this problem solved with javascript.  I
am only resorting to javascript because I have found no other work
around.

<div class="buttons">
<input type="submit" name="nice" value="Send Message"/>
<input type="submit" value="Next"/>
</div>

Graciously,

J Durden
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/facebooker-talk/attachments/20081112/d4e47318/attachment.html>


More information about the Facebooker-talk mailing list