[TYPO3] Automatic anchor tags/links with ids?

Christian Lerrahn typo3 at penpal4u.net
Sat Feb 23 12:43:32 CET 2008


Hi Dmitry,
> Christian Lerrahn wrote:
> > when you insert a content element, TYPO3 will always prepend an
> > anchor tag with its uid in the name, like e.g. <a id="c10"></a>.
> > 
> > Now, my problem is that I want to set up a CSS based print view
> > where links are displayed with the URL from the HREF parameter
> > displayed after the link text. In other words a link <a
> > href="http://blabla.com/foo.html">bar</a> will then become "foo
> > (http://blabla.com/foo.html)". The problem is that the anchors
> > mentioned above will then become "()" because they are a tags
> > without HREFs. So, what I would like to do is place an id on these
> > tags to make them look like <a id="c10" id="noprint"></a> so that I
> > can treat them separately in my style sheet. Even better would be
> > if I could use different ids for anchors, internal and external
> > links. Is this possible?
> 
> Firsts, two id attrbiutes are invalid.
> 
> Second, you want to get rid of "cXXX", look in CSS styled content TS.
> It is added there. You can unset it with one line of TS code.

Oops, my bad. I actually believed that the id that is already in there
was a "name=". But probably reading would have been better than
believing. Anyway, I don't want to get rid of the original ids because
they might come in handy. Can I maybe add a class? That would do the
trick just as well... But maybe I'll go through the CSS styled content
and see if I can figure it out by myself. ;)

Cheers,
Christian


More information about the TYPO3-english mailing list