Project

General

Profile

Actions

Bug #14732

closed

XHTML compliance of FORM objects (label tag)

Added by Martin Kutschker over 19 years ago. Updated over 18 years ago.

Status:
Closed
Priority:
Should have
Category:
Frontend
Target version:
-
Start date:
2005-05-14
Due date:
% Done:

0%

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

Description

In XHTML [ are not allowed for ids (strictly speaking they never were even for HTML). When turning on acessibility a" label" tag with a "for" attribute is generated (which contains the id of the form element).

TYPO3 uses the same value for id and name of the form element. But the [ and ] are not allowed. A solution MAY be to quote the square brackets with numeric entities.

If this is not allowed/possible then the ids must be auto-generated. I suggest form name plus md5-hash of the field name. If the form name contains invalid characters we should do a fall-back to a random prefix.

(issue imported from #M1075)


Files

class.tslib_content.php.labelfor.patch (1.58 KB) class.tslib_content.php.labelfor.patch Administrator Admin, 2005-05-17 15:41
Actions #1

Updated by Martin Kutschker over 19 years ago

Entity quoting does not help. We need to go the hash way.

Actions #2

Updated by Martin Kutschker over 19 years ago

Attached patch which uses formname and fieldname-hash.

Actions #3

Updated by Michael Stucki over 19 years ago

Fixed in 3.8.

Actions

Also available in: Atom PDF