[TYPO3-core] Accessible PopUp links

Andreas Otto ao-lists at php4win.de
Tue Nov 22 10:51:14 CET 2005


This is a CVS patch request.

Type: (Bugfix / New feature / Code cleanup)
Code cleanup

Description:
If a user wants a certain link to be opened in a PopUp window code like the 
following is used in the textfield of a content element:

<LINK 123 320x240>My link</LINK>

This will result in:

<a href="#" 
onclick="vHWin=window.open('http://www.example.com/index.php?id=123','FEopenLink','width=320,height=240');vHWin.focus();return 
false;">My link</a>

This link will fail if the website user's browser is not capable of using 
JavaScript. Furthermore search engines might have problems with this kind of 
links, too.

To make the PopUp links more accessible the generated link could look like the 
one below.

<a href="index.php?id=123" target="FEopenLink" 
onclick="vHWin=window.open('http://www.example.com/index.php?id=123','FEopenLink','width=320,height=240');vHWin.focus();return 
false;">My link</a>

We have added the URL to the HREF-attribute and we have added the 
TARGET-attribute. Now the requested page will open in a new browser window if 
JavaScript fails. If we decide to drop the TARGET-attribute the page will 
open in the existing browser window.


Branches: (HEAD / TYPO3_3-8 / TYPO3_3-7)
HEAD

Bugtracker reference:
none

Files:
class.tslib_content.php.patch


If there are no objections I will commit the patch to CVS.


Cheers,
Andreas
-- 
Noch 795398 Sekunden...

There's no future in time travel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: class.tslib_content.php.patch
Type: text/x-diff
Size: 1248 bytes
Desc: not available
Url : http://lists.netfielders.de/pipermail/typo3-team-core/attachments/20051122/0564416c/attachment.bin 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.netfielders.de/pipermail/typo3-team-core/attachments/20051122/0564416c/attachment.pgp 


More information about the TYPO3-team-core mailing list