misiek
1/27/2006 9:59:00 PM
misiek wrote:
> how to do a form only with RoR
> I got
> <%= form_remote_tag(:update => "update_div",
> :url => { :action => :add_user, :controller => "user" } ) %>
> <%= text_field("user", "name",:size => 20) %> fullname
> <input type="submit" value="Add User">
> </form>
>
> but there is part of html code
> => <input type="submit" value="Add User">
> => </form>
>
>
> I need to create only with ruby
> and more qestion:
> I need to do some extra action for example by pressing on Add User I
> need to do :action => :add_user and also call some script with
> javascript like onclick=""
>
> it is possible ?
>
> thanks for help
ok I got that
<%= submit_tag("Save" , :onclick => " " )%>
but how to put the javascript function into onclick ?
I need to by pressing Save button call for example that =>
onclick="Effect.Fade('id',{duration:0.6});"