Hello,
Im getting these two errors:
Warning: Cannot send session cookie - headers already sent by (output started at /u2.bristol/s18/es203/public_html/Test/load.php:10) in /u2.bristol/s18/es203/public_html/Test/load.php on line 11
Warning: Cannot send session cache limiter - headers already sent by (output started at /u2.bristol/s18/es203/public_html/Test/load.php:10) in /u2.bristol/s18/es203/public_html/Test/load.php on line 11
The code that generates these errors are:
<?php
session_start();
include('tmcphpimg.php');
echo "<p align=center>Loading Gallery Data....</p>";
initGallerys("http://www.student.city.ac.uk/~es203/Test/");
echo "<p align=center>...load complete (" . getNumGallerys() . " gallerys loaded).</p>";
echo "<br>";
echo "<p align=center>Transfering you to menu system...</p>";
echo "<script language=" . chr(34) . "Javascript" . chr(34) . ">";
global $MenuURL;
echo "parent.frames['Top'].location='" . $MenuURL . "';";
echo "</script>";
?>
The initgallerys function is:
function initGallerys($masterFile)
{
session_register('gallerysArray');
global $gallerysArray;
$gallerysArray = array();
$master = fopen($masterFile . "master.txt", "r");
$gUrl = "";
while((!feof($master)) && (substr($gUrl, 0, 9) != "ENDOFLIST"))
{
$gUrl = readLine($master);
if(substr($gUrl, 0, 9) != "ENDOFLIST")
{
$gBu = $gUrl;
$gArray = loadBrowseFile($gUrl);
array_push($gallerysArray, $gArray);
}
}
}
Why am I getting these errors and what am I doing wrong with my code???
Thanks
TMC