I'm trying to use this code to do this:
Code: Select all
$user =& JFactory::getUser();
$user_id = $user->id;
Once I know the user id I can do my own processing. However, the result of this code is:
Fatal error: Call to undefined function jimport() in /home/(username)/public_html/libraries/joomla/factory.php on line 159
How do I make it so that I can grab the userid of the viewing user in my application? Please help!