...HUH?? Can you post that message, or possibly even send a screenshot of that message to me? I'm really curious to see what you're talking about.
Extract() simply copies variables from an array into global scope. That's all. Using extract() should have NO effect on whether or not the cookie variables exist or whether the script is "outdated".
The only thing I can think of is that you're seeing a "Page is expired" dialog, which means you're trying to refresh a page (or go back to a page in your history) that you submitted POST variables to.
You get the message saying the page is expired because the browser knows that the page was probably generated after processing form input -- the dialog you're getting is prompting you to resubmit the SAME form input data that you submitted the first time you viewed the page with the assumption (or hope?) that resubmitting the same form inputs will generate the same page and NOT have any weird side effects.
An example of a page with side effects:
<form method="post" action="register.php">
Username: <input type="text" name="user" /><br />
Password: <input type="password" name="pass" /><br />
<input type="submit" value="Submit" name="submit" />
</form>
<?php // register.php -- registers a new user
$errors = array();
if (!isset($_POST['user'))
{
$errors[] = "Username required!";
}
if (!isset($_POST['pass']))
{
$errors[] = "Password required!";
}
if (empty($errors))
{
mysql_connect('localhost', 'user', 'pass');
$query = "INSERT INTO users (username, pass) "
. "VALUES ('{$_POST['user']}', '{$_POST['pass']}')";
$result = mysql_query($query);
if (0 == mysql_affected_rows($result))
{
errors[] = "User already exists!";
}
}
if (!empty($errors))
{
echo "<b>" . join("<br />", $errors) . "</b>\n";
}
else
{
echo "User created.";
}
?>
See, the first time you submit that page, you create the user. The second time you submit that page, you'll get the "user already exists" error. You'll also get the "page expired" error from the browser.
Okay, done rambling. Need sleep now.
Take care,
Nik
http://www.bigaction.org/