View file isn't completely displayed- Ruby on Rails -
I am trying to create a form using Ruby on Rail. However my code only shows content in the content and the rest of the content is not displayed. My code is as follows
Controller: user_controller.rb
class UserController & lt; ApplicationController def index enddif register @title = "signup" and end
see: register.html
` & Lt;% form_for: User Tax | F | & Gt%; & Lt; Fieldset & gt; & Lt; Story & gt; Sigup & lt; / Narrative & gt; & Lt; Label = "name" & gt; Name: & lt; / Label & gt; & Lt;% = f.text_field: name% & gt; & Lt; Br / & gt; & Lt; Label = "email" & gt; Email: & lt; / Label & gt; & Lt;% = f.text_field: email% & gt; & Lt; Br / & gt; & Lt; Label = "password" & gt; Password: & lt; / Label & gt; & Lt;% = f.password_field: Password% & gt; & Lt; Br / & gt; & Lt;% = submit_tag "signup" ,: class = & gt; "Submit"%> & Lt; / Fieldset & gt; & Lt;% end% & gt;
Any help is appreciated.
add =
:
Lt;% = form_for: user do | F | & Gt%;
form_for
is a method that gives the string. & lt; %% & gt;
executes the code,
& lt;% =%>
Inserts the returned value into html.
Comments
Post a Comment