I am having problelms with the sytax necessary to load an image.
Site layout
Site //home dir
....bamboopages // sub dir
........photos // sub dir under bamboopages
..............p0095.jpg // image in photos dir
........photos50 // sub dir under bamboopages
..............t0095.jpg // image in photos50
........alphalist.htm // calling page for d0095.php
........d0095.php // page with sytax prolbem
....other sub directories
....index.htm
alphalist.htm sets the $Post_variables and returns to alphalist.htm which has a list of links.
The link for d0095.php calls the page and display correctly until I add a php if statement.
The page then displays correctly except there is no image displayed. The image place holder displays in the correct size but no image.
The code:
<?php
if (!empty($_POST["picsize"])) {
$photo = $picsize;
} else {
$photo = "full size";
}
switch ($photo) {
case "full size":
echo ('<img src="//bamboopages//photos//p0095.jpg" width="500" height="375">');break;
case "half size":
echo('<img src="//bamboopages//photos50//t0095.jpg" width="250" height="187">');break;
default :
echo ('<img src="//bamboopages//photos//p0095.jpg" width="500" height="375">');break;
}
?>
If I replace the php code and just have a straight html <img scr= then the page display the image called.
Any help and on what I am doing wrong, appreciated.
Bert