[dokuwiki] Session variables being reset?

  • From: Raam Dev <raamdev@xxxxxxxxx>
  • To: dokuwiki@xxxxxxxxxxxxx
  • Date: Tue, 05 Dec 2006 15:16:31 -0500

On test.php I have the following:

<?php
session_start();
$_SESSION['myvar'] = "abc123";
?>

Then, from anywhere within DokuWiki, for example at the top of /lib/tpl/default/main.php, I add the following:

session_start();  // tried with and without this line
echo $_SESSION['myvar'];

The session variable appears to be empty and does not echo "abc123". However, if I add the following to main.php:

session_start();
$_SESSION['myvar'] = "abc123";
echo $_SESSION['myvar'];

everything works as expected. Why wouldn't the session variables carry over when they're set on a page outside DokuWiki? Am I missing something?

Thanks!
Raam
--
DokuWiki mailing list - more info at
http://wiki.splitbrain.org/wiki:mailinglist

Other related posts: