Sorry DJ,
When the page first loads there should be a 'starter image' displayed in the center of the page. But this does not display due to the error
'Notice: Undefined index: Picture in'. Even after i changed what you told me to in the url
Quote:
|
quote:<a href="http://localhost:8080/Website.php?Picture=Eye.jpg?>
|
But, i've changed the code to include the
Code:
$ThisPicture=$_GET['Picture'];
if(!isset($_GET['Picture']))
{
echo "<img src='images/water.jpg' width='353' height='280' alt=''></td>" ;
}
else
{
echo "<img src='images/$ThisPicture' width='353' height='280' alt=''></td>" ;
}
This displays the water.jpg image at startup, and when i click a link, this image is changed to the value of $ThisPicture, which is what i want and the error dissapears (as $_GET[] has an index after i click the link).
So this is solved, though i'm unhappy about finding a way to supress the error rather than fixing it altogether. The error (
'Notice: Undefined index: Picture in') still appears in my site as i have error reporting on. I would like to find a way to fix it rather than hide it. But if there isn't a way then i'm happy too.
As for the easy way to refresh the page, I was just wondering if theres a shortcut to say in a href tag 'Link to this page', rather than writing out the url of the same page. I remember you told me earlier that using php i will need to refresh the page, but with javascript i can refresh just the html section i wish. I will look into using javascript, but i dont think i should be asking Javascript question on a PHP forum.
Thanks for all your help DJ... There will be a thanks to you on the finished site.
A true friend stabs you in the back