Forum How do I...?

How to filter :after result?

fbrzvnrnd
Hi,

I have a index. This index has text like:

  <a class="internamente" href="AISM_seconda_revisione_attiva_0006.xhtml#nuvola9"> vedi <span>(1)</span>, </a><a class="internamente" href="AISM_seconda_revisione_attiva_0007.xhtml#nuvola32"> vedi <span>(2)</span>, </a><a class="internamente" href="AISM_seconda_revisione_attiva_0007.xhtml#nuvola33"> vedi <span>(3)</span>, </a><a class="internamente" href="AISM_seconda_revisione_attiva_0009.xhtml#nuvola41"> vedi <span>(4)</span>, </a>

[et ceteare]


For the web/ebook is ok, but if I use in css something like:

a.internamente:after {content: ", see page " target-counter(attr(href, url), page);}


...often I have this problem: when the link href has the target in the same page of the previous, I got a lot of:

see page 31, see page 31, see page 31 (...)


...because all the target (for example) are in page 31.

Is there a way to put a condition in :after to hide itself if the attr(href, url), page is the same of the previous one? I cannot write a script to delete in xhtml, because the number of page is not in xhtml...


Thank you


f.

mikeday
It is not possible to do this with CSS, you will need to use JavaScript as described in this thread.
fbrzvnrnd
Thank you, I'm reading now.