Here is the thing… on my WordPress blog, I added in a Log In Form to the sidebar, so users can log in right from the page they are currently on. I did not do this as a widget, as where the widget’s appear on my theme are to small for a log in form. I added it into the sidebar.php file of the theme, so it appears above the two columns where widgets appear. What I want to do (and I am not quite sure how to do it) is to make it work similar to the META widget from WordPress. Basically make it so that the log in form only appears if a user is not logged in. If a user is logged in, I want it to display user links such as “Dashboard”, “Profile” etc. How do I do this? Here is the full code of my sidebar.php file (the code for the existing login form in the sidebar is bold):
It may also help to know that my WordPress installation is 3.0 and is using the Theme My Login plugin by Jeff Farthing so the registration pages match my site theme, and users who log in are rerouted back to the page they logged in from instead of the backend.