Getting and posting info from database?

If you are completley new to Ror I would suggest reading some of the thousands of tutorials on the web, or one of the several books about Rails that are out now (Agile Web Development With Rails 2nd Edition is the crowd favorite).

The answers to your questions aren't that simple. How does the application know what user is logged in? You can search your database like this...

@user=User.find_by_username(Bob)

Where 'username' is the column in the DB you want to search and 'Bob' is what to search for. The entire row will be returned as an array @user, so then you can use @user.location @user.first_name @user.last_name or @user.whatever

Usually developers store the user_id in the session information, so you can do something like @user = User.find(session[:id])

I hope this gets you on the right path, but you really need to start reading up... :slight_smile: