On 26 Dec 2015 22:35, "fugee ohu" <fugee279@gmail.com> wrote:
>
> they're the same, <%= render 'form' %> is all they contain other than links and either <h1>New model</h1> or <h1>Editing model</h1>
I said to look at the HTML not your source code. The form tag is the HTML generated by the form_for code.
Also please don't top post, as I have asked before. Thanks.
Colin
>
> On Friday, December 25, 2015 at 4:14:36 AM UTC-5, Colin Law wrote:
>>
>> On 25 December 2015 at 07:16, fugee ohu <fuge...@gmail.com> wrote:
>> > how does rails know if it should submit a form to update or create? the form
>> > is rendered by either new or edit so on submission how does rails know which
>> > action originally rendered the form?
>>
>> Have a look at the html for the edit and new pages and I think you
>> will see a difference. Look at the form tag in particular.
>>
>> Colin
>
> --
> You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
> To post to this group, send email to rubyonrails-talk@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/791ad873-6fde-465e-9d91-c945d4c911d4%40googlegroups.com.
>
> For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CAL%3D0gLtsCHdRv_TNDNj%3DgA7BRVrEYYuvMFpywJanmBdDX9C1CA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
No comments:
Post a Comment