I hate to ask, but can some one help me out on this one? I've made a small app in which users login, and once logged in they type their names in to a textbox, submit it, and once submitted it says "Hello and Welcome <their name>". For authentication I used acts_as_authenticated. The app works except for the adding names feature. Can you help me? This is the code that i put, but I can't get the submitted name to appear next to "Hello and Welcome" so all instead of seeing "Hello and Welcome <name>", it shows Hello and Welcome. Here's the code for my view
<html> <head> <title> My little login APP!</title> <%= javascript_include_tag :defaults %> </head> <body> <h1>My little login APP!</h1>
<%= error_messages_for :user %> <% form_for :name do |f| %>
<%= form_remote_tag (:update => "name", :url => { :action => :add_item}, :position => "top") %>
<p>Please submit your name:</p> <%= text_field_tag :newitem %> <%= submit_tag "Submit" %>
<ul id="name"> <p><h3>Hello and Welcome!</p></h3> </ul>
<hr> </hr>
<p><b><i><%= current_user.login %></p></b></i> <p><a href="account/login"><%= submit_tag 'Logout' %></a></p> <% end %> </body> </html>