Forum Moderators: coopster
header("Location: [localhost:8080...]
the setskin.php3 page is where the user selects the skin. i was aiming for refreshing the page after selection, so that the user can see the look. but the header location part does not seem to refresh the page in any way. how come?
is there anyway of refreshing that page after a skin has been selected?
kumar
using $_SERVER['PHP_SELF'] [ca.php.net]
my script is a seperate file to setskin.php3. wouldnt that mean that the $_SESSION['PHP_SELF'] would be session.php3 (the script file) rather than setskin.php3, which is what i want it to be?
this is the script that on every page called check_session.php3
<?php
// start the session
session_start();
header('Cache-control: private'); //IE 6 Fix
if ( isset($_SESSION['skin']) ) {
$skin = $_SESSION['skin'];
}
else {
$skin = "wolf.css";
}
?>
this is the script that start session(session.php3)
<?php
session_start();
header("Cache-control: private"); //IE 6 Fix
// Get the user's input
$sname = $_GET['sname'];
// Register session key with the value
$_SESSION['skin'] = $sname;
header("Location: [localhost:8080...]
?>
seems ok to me