You are here: sessions headache... « PHP Programming Language « IT news, forums, messages
sessions headache...

Posted by Misteka on 11/14/93 11:54

Hi guys,

Here is my code. Redirect to index.php not working. Have trawled
through old topics but can't fix it.

<?php

session_start();

if (isset($_POST["login"])) {
$missingfields = array();

foreach ($_POST as $var=>$val) {
if ($val == "") {$missingfields[$var] = $val;}
}

if (count($missingfields) > 0) {
print "You missed out one or more fields:<BR />";
foreach($missingfields as $key=>$value) {
print $key . ", ";
}
}
else {
foreach ($_POST as $key => $value) {
$_SESSION[$key] = $value;
}
session_write_close();
header("Location: http://shsc-int_staging.brookes.ac.uk/index.php");
}
}
?>

Any help or assistance appreciated.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация