Project

General

Profile

Actions

Bug #64989

closed

Typoscript renderObj IMAGE: empty altText renders "alt" without params in HTML

Added by René Schäfer about 9 years ago. Updated over 8 years ago.

Status:
Closed
Priority:
Should have
Category:
TypoScript
Target version:
-
Start date:
2015-02-11
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
5.5
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

Hello together,

I'm praud to report my first bug and you can hopefully recognise what i mean. I found that by rework a picture-menu in Typoscript after upgrade an TYPO3 4.7 to 6.2

It was hard to find the right new way to get pictures out of an typoscript object. I thougt it would be easier as in 4.7. but it was more complex instead..

How ever, her is the code to rende an image:

10 = FILES
10 {
references {
table = tt_content
fieldName = image
}
renderObj = IMAGE
renderObj {
file {
treatIdAsReference = 1
import.data = file:current:publicUrl
}
titleText.data = file:current:title
altText.data = file:current:alternative
}
}

The HTML shows in short:
<img ... alt="What ever.." ...>

BUT if the alternative field if empty, the rendering shows:
<img ... alt ...>

The "alt-Tag" is not properbly deleted. The use of "altText.required=1" does not help.

Thanks for working on TYPO3 in general!
Greetings from Potsdam
René

Actions

Also available in: Atom PDF