Sun 09 Aug |
|
How to make a login link in Joomla 1.5 is asked quite regularly in forums. Here's how to do it and add a bit of interactivity with the user. Code updated 18.10.2010 to latest J1.5-21 The first way is to add a menu item to the login screen. In the Menu Manager select "New" and type "External Link". The url to use is http://www.yoursite.com/index.php?option=com_user&view=login You can also add it directly in your template at a suitable position and style it appropriately - <!--login link--> If we want to add a bit of user interactivity then we first need to get the users name with a JFactory call and store it in a variable which we place in the php section of the template - $username =& JFactory::getUser(); Then we can use this to greet the user if they are logged in and also provide a logout link. <!--login link--> |
Last Updated on Friday, 29 April 2011 10:08 |