[TYPO3] img tags being removed from plugin output

Bill Stoltz bstoltz81 at comcast.net
Thu Jul 19 04:45:02 CEST 2007


More testing, more confusion....

I have the exact same problem if I take these images and put them in an 
image content element. I have included selected generated HTML to show 
the extra row, but no image.

yet what is very interesting is that in the backend, in the image 
content element, it lists all 3 images (2 that work, 1 that does not 
display on front end). Yet in the backend, you can see ALL 3 thumbnails 
of the 3 images.

I have looked for things that are different, but I can't find it. They 
are all roughly 468 x 60. they are all 72 dpi, and 24 bit depth.
They all display fine in a browser, and in windows explorer, or MS 
paint. I have renamed the files to make sure there are no special 
characters in the file names.

For some reason, Typo3 will not display these images.

I am sure it is a simple setting. probably some TS some where that was 
put in for something else.

I would really appreciate any help on this.

Bill
-------- image element generates source code ----
<div id="colNormal"><a id="c764"></a><h1>try image element</h1><div 
style="text-align:center;">
<table width="469" border="0" cellspacing="0" cellpadding="0" 
style="margin-left: auto; margin-right: auto" class="imgtext-table">

<tr><td colspan="1"><img src="clear.gif" width="469" height="1" alt="" 
/></td></tr>
<tr><td valign="top"><img src="uploads/pics/LongHorn.jpg" width="468" 
height="59" border="0" align="top" alt="" title="" /><br /></td></tr>
<tr><td colspan="1"><img src="clear.gif" width="1" height="10" 
border="0" alt="" title="" /></td></tr>
<tr><td valign="top"><img src="uploads/pics/PeachtreeBank.jpg" 
width="469" height="59" border="0" align="top" alt="" title="" /><br 
/></td></tr>
<tr><td colspan="1"><img src="clear.gif" width="1" height="10" 
border="0" alt="" title="" /></td></tr>
<tr><td valign="top"><br /></td></tr>
</table></div><img src="clear.gif" width="1" height="6" border="0" 
class="spacer-gif" alt="" title="" /><br />

Bill Stoltz wrote:
> Johannes, thanks for the quick reply.
> 
> According to the code, IMAGE() calls stdWrap() at the very end. It looks 
> like cImage() does the work and could filters things.
> 
> Based on the debug output from stdWrap(), what stdWrap gets, already has 
> the <img> tags, so they are getting removed AFTER stdWrap.
> 
> I forgot to mention this, but yes all the image files do exist, the 
> paths are correct. I put the path to each JPG into the browser and got 
> each image to display. The sysfolder is not hidden, and none of the 
> images in the sysfolder are hidden.
> 
> In my limited understanding, these images would have been removed before 
> stdWrap() anyway, if the image was hidden.
> 
> I am sure this will be an easy fix, but I don't know typo3 Core well 
> enough to know where to go next, or how best do debug.
> 
> Is there other TS debug, like that for stdWrap?
> 
> Any suggestions on other places to look?
> 
> Johannes Künsebeck wrote:
>> Bill Stoltz wrote:
>>> help -
>>> I have a plugin that is returning content that includes html tags to be
>>> displayed. All the tags are returned except for some img tags.
>>>
>>> I know it is not the plugin issue - but I don't know where to look, or
>>> how to debug.
>>>
>>> I have validated that the plugin returns valid html, including <img> 
>>> tags.
>>>
>>> I have turned on stdWrap debug, and it prints all the html and <img> 
>>> tags.
>>>
>>> However, if I turn off debug, and view the html source that is
>>> generated, then some, but not all <img> tags are removed. The <a> tags
>>> that were around the <img> are still there.
>>>
>>> The best I can figure is that something that eventually calls stdWrap
>>> must be stripping out the images, but I can't tell what routine is doing
>>> this.
>>>
>>> Any ideas on where to look? other debug I can turn on?
>>>
>>> I don't know if it matters, but the plugin that I am using is
>>> macina_banners.
>>>
>>>
>>> ---------------------------------------------------------------
>>> page source code showing missing <img> tags - not banneruid=25 is
>>> missing <img> tag
>>> ----------------------------------------------------------------
>>>         <!--  Plugin inserted: [begin] -->
>>>            <!--- banners Module extension begin -->
>>> <table border="0" cellpadding="0" cellspacing="0">
>>>
>>>   <tbody><tr>
>>>     <!--- banners Module row begin -->
>>>     <td align="left" valign="middle"><div style="margin: 0px;"><img
>>> src="typo3temp/pics/1771f39da6.jpg" alt="" title="" border="0"
>>> height="59" width="468"></div>
>>>
>>> </td>
>>>     <!--- banners Module row begin -->
>>>   </tr>
>>>       <tr>
>>>     <!--- banners Module row begin -->
>>>     <td align="left" valign="middle"><div style="margin: 0px;"><a
>>> href="index.php?id=659&amp;no_cache=1&amp;no_cache=1&amp;tx_macinabanners_pi1%5Bbanneruid%5D=25"></a></div> 
>>>
>>>
>>> </td>
>>>     <!--- banners Module row begin -->
>>>   </tr>
>>>       <tr>
>>>
>>>     <!--- banners Module row begin -->
>>>     <td align="left" valign="middle"><div style="margin: 0px;"><a
>>> href="index.php?id=659&amp;no_cache=1&amp;no_cache=1&amp;tx_macinabanners_pi1%5Bbanneruid%5D=24"><img 
>>>
>>> src="typo3temp/pics/8dd595eff1.jpg" alt="" title="" border="0"
>>> height="64" width="468"></a></div>
>>> </td>
>>>     <!--- banners Module row begin -->
>>>   </tr>
>>>     ---------------------------------------------------------------
>>> output from stdWrap ..... banneruid=25 had <img> tag
>>> ---------------------------------------------------------------
>>>     <!--  Plugin inserted: [begin] -->
>>>            <!--- banners Module extention begin -->
>>> <table border="0" cellpadding="0" cellspacing="0">
>>>
>>>   <tr>
>>>     <!--- banners Module row begin -->
>>>     <td align="left" valign="middle"><div style="margin-top:0px;
>>> margin-right:0px; margin-bottom:0px; margin-left:0px; "><img
>>> src="typo3temp/pics/1771f39da6.jpg" width="468" height="59" border="0"
>>> alt="" title="" /></div>
>>> </td>
>>>     <!--- banners Module row begin -->
>>>   </tr>
>>>       <tr>
>>>     <!--- banners Module row begin -->
>>>     <td align="left" valign="middle"><div style="margin-top:0px;
>>> margin-right:0px; margin-bottom:0px; margin-left:0px; "><a
>>> href="index.php?id=659&amp;no_cache=1&amp;no_cache=1&amp;tx_macinabanners_pi1[banneruid]=25" 
>>>
>>>> <img src="uploads/tx_macinabanners/BariItalianFoodsWebBanner468x60.gif"
>>> width="468" height="60" border="0" alt="" title="" /></a></div>
>>> </td>
>>>     <!--- banners Module row begin -->
>>>   </tr>
>>>       <tr>
>>>     <!--- banners Module row begin -->
>>>     <td align="left" valign="middle"><div style="margin-top:0px;
>>> margin-right:0px; margin-bottom:0px; margin-left:0px; "><a
>>> href="index.php?id=659&amp;no_cache=1&amp;no_cache=1&amp;tx_macinabanners_pi1[banneruid]=24" 
>>>
>>>> <img src="typo3temp/pics/8dd595eff1.jpg" width="468" height="64"
>>> border="0" alt="" title="" /></a></div>
>>> </td>
>>>     <!--- banners Module row begin -->
>>>   </tr>
>>>    
>>
>>
>> I think the images are made with the IMAGE-cObj.
>> When it does not generate an image (for example, because it does not 
>> find the original image file) , it outputs no image tag.
>> It looks like all images are scaled by typo3 to 468px width but the 
>> one that's missing already has the right size (using the original 
>> filename, not typo3temp/pics)
>> So a quickfix could be to upload the image 
>> (ariItalianFoodsWebBanner468x60.gif) a little bit bigger.


More information about the TYPO3-english mailing list