Jump to content

[SOLVED] image display not working - php imbedded in html with css


kate_rose

Recommended Posts

Hi again,

 

I have a series of web pages & I am using SESSION variables to pass values from one to another.  I am trying to use one to display an image with the following code:

 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>
<style type="text/css">
#wrapper{
    position: absolute
    top: 0px;
    left: 0px;
    margin: 0px;
    padding: 0px;
    border: 0px;
background-color: #669999;
width: 1000;
height: 410px;
overflow: visible;
}
#navigation {
position: absolute;
top: 420px;
left: 0px;
margin: 0px;
padding: 0px;
border: 0px;
background:#C96;
height: 40px;
width: 100px;
overflow: hidden;
}
</style>
<body>
<div id="wrapper">
<?php
$imagepath = $_SESSION['image_path'];
echo "<img src=\"$imagepath\"/>";
echo "<p> ljljlkjlj </p>";
?>
<img src="
<div id="navigation"> 
<form action="browser.php" method="post"> 
<input type="submit" name="show" value="escape"> 
<input type="submit" name="show" value="previous"> 
<input type="submit" name="show" value="next"> </form>
</div>
</div>
</body>
</html>

 

The SESSION 'image_path' definitely has a value in it because I made it reload & echo it on the previous page to check.

The echo <img etc. has worked just fine when tested on another page that contained no html or css.

The paragraph <p> below the image display which is just for testing is displaying just fine.

I also just tried displaying the same pic from outside the php code tags & it worked fine though I did use the actually imagepath & not the SESSION variable.

I just can't figure out why its not working.

 

Any thoughts?

 

Thanks,

 

Kate

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.