Project

General

Profile

Actions

Bug #20607

closed

Wrong rendering of HTML content element

Added by Krystian Szymukowicz almost 15 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Should have
Category:
-
Target version:
-
Start date:
2009-06-11
Due date:
% Done:

0%

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

Description

If content element HTML has open tag, fe:
<div id="foo">
then it will be closed automatically but should not.

This behaves like that if I choose the latest "CSS Styled Content" in "Include static (from extensions)".

If I choose "CSS Styled Content TYPO3 4.2" then the tag is not closed automatically.

(issue imported from #M11316)


Files

11316v1.patch (1.17 KB) 11316v1.patch Administrator Admin, 2009-06-14 16:07
11316_v2.diff (2.97 KB) 11316_v2.diff Administrator Admin, 2010-03-27 10:21

Related issues 1 (0 open1 closed)

Has duplicate TYPO3 Core - Feature #22225: html content wrapClosed2010-03-03

Actions
Actions #1

Updated by Krystian Szymukowicz almost 15 years ago

It appears that from 4.3 every content element its wrapped with <div id="cXXX" class="csc-default" >|</div> and this is the reason why it closes my opened tag.

Actions #2

Updated by Marcus Biesioroff almost 15 years ago

Small correct: 4.3 doesn't complete your tag but wraps your 'non-complete' tag into complete <div class="csc-default">|</div> so if your tag is div the browser threads next found </div> as end of your part... The solution is "No frame" type of frame to avoid csc-defauld wrapping. (I posted it on the typo3.projects.content-rendering list)

Actions #3

Updated by Krystian Szymukowicz almost 15 years ago

As an explanation why I use wrappers in HTML CE.

I use it in case when:
a) wrapper will be not available to end user and used at pages that editor can not edit anyway
b) wrapper will be used only once or two in whole webpage.

There are "better" ways (TV, ICE Box, kb_nescefe) but first you need to add wrapper to system then exclude it from end user. Its time consuming and what for: to use it just once? HTML CE wrapper are much faster.

But anyway as there are workarounds and the behavior can be easily changed in TS I think it is not a problem.

I would only make a note in 4.3 changelog so this people who uses "extremely quick HTML CE wrapper" may know why their layout just broke after upgrade to 4.3.

So please close this bug.

Actions #4

Updated by Susanne Moog about 14 years ago

Attached a new patch which does:

- Keep the default frame (see deeper reasons in the discussion)
- Define a label for the default frame ("Default Frame" instead of no
label, so one can guess that there will be a frame around the element)
- Define a new section_frame called "No Frame" which renders the element
like v4.2 did and which can be used for wrapper HTML elements.

Actions #5

Updated by Ron Hall about 14 years ago

I too have run into this issue when upgrading legacy sites to 4.3. I have dealt with it using the following TS:

tt_content.stdWrap.innerWrap.cObject.default.if {
value = html
equals.field = CType
negate = 1
}
tt_content.html.dataWrap = <a id="c{field:uid}"></a>|

This will keep the HTML element from being wrapped in a div but still retains the ability to link to it via the anchor tag. Be aware the space before and after fields are nullified. But the rendering is close to that in 4.2 and only affects the HTML CE.

I don't have this problem in later installations as I do not use the HTML CE in ways where the wrapping div causes an issue.

Actions #6

Updated by Francois Suter about 14 years ago

Committed Susanne's solution to trunk in revision 7250

Actions #7

Updated by Benni Mack over 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF