#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2004
    Posts
    103
    Rep Power
    10

    Arrow Handling two forms on same page!


    Hi.

    I have my registration and login forms on same page. If a user is registered she can login or get registered first.

    Now I am confused about how to handle it in my controller. How can I handle it in same controller?

    The structure is like below:
    Controller: usr_controller. This has one method 'index'
    Code:
    def index
    ...
    end
    View: usr/index.html.rb -> this has both register and login forms.

    Please tell me how can I do this.
    Thanks
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jan 2006
    Location
    New Jersey
    Posts
    219
    Rep Power
    137
    In your form declarations, specify the action and controller to use.

    If you show the code for your view I can be more specific.

IMN logo majestic logo threadwatch logo seochat tools logo