[TYPO3-english] Automatically add accessability icon to external links

Stefan Isak stefanisak at googlemail.com
Fri Feb 25 14:31:38 CET 2011


Oh, that's right. Never thought about that in this case.
Works like charm.

I used page.headerData for once to have access to baseUrl property.
So that's my solution now:

page.headerData.1001 = HTML
page.headerData.1001.value (
  <style type="text/css">
    #main p a[href^="http://"] {
	background: url("icon.gif") no-repeat scroll 0 2px transparent;
	padding-left: 13px;
    }

   #main p a[href^="{$baseURL}"] {
	background: none;
	padding-left: 0;
   }
  </style>
)

Thanks!


On Feb 25, 2011, at 11:18 AM, Kay Strobach wrote:

> Hi Stefan,
> 
> you can do it with css by cehcking the href attribute ;)
> 
> http://www.w3.org/TR/CSS2/selector.html#attribute-selectors
> http://webdesignblog.de/webdesign/nutzen-des-attribute-selector-mit-css/
> 
> Regards
> Kay
> 
> Am 25.02.2011 11:06, schrieb Stefan Isak:
>> Hi,
>> 
>> is there somehow a chance to automatically add a class like external-link-new-window to every external link, so that it's not necessary anymore to update every link in RTE manually.
>> Maybe there's a setting in RTE parse func? I can't find any information about it.
>> 
>> Thanks a lot.
>> Cheers
>> Stefan
>> 
> 
> 
> -- 
> http://www.kay-strobach.de - Open Source Rocks
> _______________________________________________
> TYPO3-english mailing list
> TYPO3-english at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-english



More information about the TYPO3-english mailing list