Why does my smiley show up as bytes?

I use a smiley on several webpages, so I thought I could access it from a directory includes.

<img src="<?php include $_SERVER['DOCUMENT_ROOT'] . '/includes/images/smiley1.png' ; ?>" width="100" height="100" alt="smiley here" />

But instead, the smiley shows up as bytes, a long long line of weird characters!

I thought it was magicquotes causing the problem, so I disabled that, but it still shows up the same.

Any tips about what is happening please?

You are including the file directly into your PHP page where you have the snippet that you show.
Be aware that images are requested and downloaded separately from the html or php source file.


<img src="/includes/images/smiley1.png" width="100" height="100" alt="smiley here" />
Sponsor our Newsletter | Privacy Policy | Terms of Service