title: Joomla User login check
body: <p>First I am not a joomla developer. My friend has a web site created with joomla 1.5. In webroot there are some joomla files. I created a directory in webroot "mydirectory" and i have an index file in this directory. I try to access joomla's user info in this page i grab the user object but it doesn't work.</p>
  
  <pre><code> //i included joomla core  files
   $user =&amp; JFactory::getUser();
  
   if ($user-&gt;get('guest')) {
       echo 'guest';
   } else {
   echo 'not guest';
   }
  </code></pre>
  
  <p>when I log in to my account, it says 'guest' again.</p>
  
  <p>Also, I can't find anything in Joomla's session class.</p>
  
  <pre><code>$session =&amp; JFactory::getSession();
  </code></pre>
  
  <p>Thanks</p>