Solved

php how do I display an image?

Posted on 2014-10-26
3
131 Views
Last Modified: 2014-10-26
The url is http://lindamatthews.net/test/open.php

and open.php is

<?php error_reporting(E_ALL);?>
<?php include("header.php"); ?>
<?php include("menu.php"); ?>
<?php
echo "<div class=\"content\">";
echo "<img src=\"art/zen20.jpg\" style=height:425px>";
<?php include("footer.php"); ?>
?>

All I get is a blank screen. No image.
0
Comment
Question by:padmasambhava
3 Comments
 
LVL 58

Accepted Solution

by:
Gary earned 500 total points
ID: 40405069
Change your code to the following, check the paths for the included files - what do you get?

<?php
error_reporting(E_ALL);
ini_set('display_errors', 1);

include("header.php");
include("menu.php");

echo '<div class="content">';
echo '<img src="art/zen20.jpg" style="height:425px">';
echo '</div>';

include("footer.php");
?>

Open in new window

0
 
LVL 24

Expert Comment

by:mankowitz
ID: 40405083
also, try to view source. That might give you a hint.
0
 

Author Closing Comment

by:padmasambhava
ID: 40405164
Thanks to both of you!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I imagine that there are some, like me, who require a way of getting currency exchange rates for implementation in web project from time to time, so I thought I would share a solution that I have developed for this purpose. It turns out that Yaho…
This article discusses four methods for overlaying images in a container on a web page
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to dynamically set the form action using jQuery.

912 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now