Topic: Submitting a form

I have a really simple for

<form method="post" action="http://localhost:3000/clients">
  <table border="0" cellspacing="0" cellpadding="0">
    <caption>Log In</caption>
    <tbody>
      <tr>
        <td>Username</td>

        <td><input type="text" name="username" id="username"></td>
      </tr>
      <tr class="even">
        <td>Password</td>
        <td><input type="password" name="password" id="password"></td>
      </tr>
      <tr>
        <td colspan="2"><input type="submit" name="login" id="login" value="login"> <a href="http://localhost:3000/clients"> bypass </a> </td>

      </tr>
    </tbody>
  </table>
</form>

but when i press the login button i get a error that reads:

Unknown action

The action 'create' could not be found for ClientsController

Re: Submitting a form

Do you have something like this in your app/controller/clients_controller.rb file?

def create
    *your create code*
end

Re: Submitting a form

Thanks

Re: Submitting a form

Hey Moises,

If you haven't already seen it, look at Ryan's railscast on building an authentication system from scratch. Even if you aren't working specifically on authentication, the video includes many of the base concepts you need to learn to build any app in Rails.

http://railscasts.com/episodes/250-auth … om-scratch

Change is a vector. You can have all the change in the world, but if it doesn't go in the right direction, what good is it? | techonamission.com

Re: Submitting a form

Thanks that is a really nice video i will check out more of there videos

Re: Submitting a form

Yeah, they're really good. I just started learning rails a couple months ago and those videos have helped me a ton!

Change is a vector. You can have all the change in the world, but if it doesn't go in the right direction, what good is it? | techonamission.com