Login redirect help please

Started by gadeercam, November 23, 2010, 05:37:48 PM

Previous topic - Next topic

gadeercam

Hi Guys,

A little background...  I have a 24/7 live wildlife cam site.  I have a community chat but I want to add a forum.

I'm new to SMF and have a problem with redirecting back to the login page.   Sometimes it works but most of the time it does not.

I'm using SMF v2.0 RC4 on a Windows server hosted at Godaddy.

Forum link is hxxp:gadeercam.com/forum [nonactive]

An example login page would be hxxp:gadeercam.com/normal2camwchatx.php [nonactive]

The beginning of the file is:
<?php
   require_once('forum/SSI.php');
   $_SESSION['login_url']  = 'ht tp: //www . hxxp:gadeercam.com [nonactive]' . $_SERVER['PHP_SELF'];
   $_SESSION['logout_url'] = 'ht tp://www . hxxp:gadeercam.com [nonactive]' . $_SERVER['PHP_SELF'];
?>

And the login code is:
            <?php
echo "loginurl:" . $_SESSION['login_url'] . "<br><br>";
         
      if ($context['user']['is_guest'])
      {   
         ssi_login();
      }
      else
      {   
         ssi_welcome();
         echo "<br><br>Click here to ";
         ssi_logout();
      }         
            ?>

I echoed $_SESSION['login_url'] just to make sure it was setting correctly.

I tried the Remember Position After Login/Logout mod but had no effect so I removed it.  The only mod is the different theme.

On logoff sometimes I get this error message:
Session verification failed. Please try logging out and back in again, and then try again.

If I log in and navigate back to hxxp:gadeercam.com/normal2camwchatx.php [nonactive] and use the log off link there, the log off redirect seems to work.

Seems to work on Firefox better than IE or Chrome.

If you want you can use testuser/testuser to give it a try.

Any help or ideas is greatly appreciated,

Thanks,
David



Deaks

its loging on and off for me fine ... btw was that pheasants I saw?
~~~~
Former SMF Project Manager
Former SMF Customizer

"For as lang as hunner o us is in life, in nae wey
will we thole the Soothron tae owergang us. In truth it isna for glory, or wealth, or
honours that we fecht, but for freedom alane, that nae honest cheil gies up but wi life
itsel."

Advertisement: