turble
04 Jan 2008, 01:52 PM
I am looking for a way to completely get rid of the image place holder for IE when displaying my web page. Instead I want missing images to simply display ONLY the Alt text without a placeholder when a file is missing, the same way Firefox and Safari do.
I know this is a huge discussion, possibly among every board I have come across the past few days, but all I have been seeing are options on how to re-size the IE place holder. I have not see any posts for how to simply get rid of it all together. (Other than changing some settings in my browser, which of course doesn't help my viewers)
Is this even possible? Has anyone heard of a Javascript option for this or possibly a re-write that allows my img code to be skipped by IE users if a file is missing?
--------------------------------------------------------------------------
An example of what I am trying to accomplish...
$imageString = "<img src=./image/".$myimage.".jpg alt=$myimage>"
I have a variable ($myimage) that is in a ForEach loop that displays a different image based on what the user inputs and is stored in MySql. In the Images folder, I have a set amount of .jpg images that will display if the exact file name matches the string, if not, it displays the variable id in Alt text.
In IE, it appears just plain messy with all of the missing image placeholders, but works wonderfully in the other browsers.
I know this is a huge discussion, possibly among every board I have come across the past few days, but all I have been seeing are options on how to re-size the IE place holder. I have not see any posts for how to simply get rid of it all together. (Other than changing some settings in my browser, which of course doesn't help my viewers)
Is this even possible? Has anyone heard of a Javascript option for this or possibly a re-write that allows my img code to be skipped by IE users if a file is missing?
--------------------------------------------------------------------------
An example of what I am trying to accomplish...
$imageString = "<img src=./image/".$myimage.".jpg alt=$myimage>"
I have a variable ($myimage) that is in a ForEach loop that displays a different image based on what the user inputs and is stored in MySql. In the Images folder, I have a set amount of .jpg images that will display if the exact file name matches the string, if not, it displays the variable id in Alt text.
In IE, it appears just plain messy with all of the missing image placeholders, but works wonderfully in the other browsers.