Christophe Guillon wrote:
Hello
I would like to have a hypertext link which, when I click on it, leads
to a web page where a certain word is highlighted. Depending on the
link, the same target page would be displayed but with a different
word highlighted.
From what you say, I understand you have a set of known links that
should highlight some specific text on known target pages. If I am
right, you could also think of using :target CSS selector, keeping in
mind this is a CSS 3 feature that only last Mozilla/Gecko browsers are
able to render right now.
Basically, you could have your target text properly marked-up in your
target page:
<span class="highlight" id="hid">example</span>
Then somewhere else you have the following link:
<a href="path-to-target-page#hid">link</a>
Plus the following CSS rule:
..highlight:target { background-color: yellow ; }
You can see an example of this at
http://www.relinquiere.com/internals/glossary (each word of the glossary
leads to a highlighted example).
--
Want to spend holidays in France ? Check
http://www.relinquiere.com/