Special Behavior - Possible?

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View
   I'm building a personal Web site (www.mrc5305.com) that has both  
narrative and links from other pages.  For example, I have a page of  
narrative that has several anchors (e.g. <a id="some_name">) that I can  
use to link back to that text from other pages.  That works, but I'd  
like something more: have the narrative text associated with the anchor  
to be displayed with a different background and/or text color when  
linked from other page(s) - versus how it's displayed on the "narrative  
   I don't know that I've ever seen such behavior in a Web site, so I  
don't know if it can be done (with <div>, <span> or something else).  Is  
something like this possible?  If so, how?  TIA

This email has been checked for viruses by Avast antivirus software.

Re: Special Behavior - Possible?

7/25/2015, 10:32 PM, MikeCopeland wrote:

 > For example, I have a page of
Quoted text here. Click to load it

If I understand you correctly, the :target pseudoclass might be what you  
need, see

It does not distinguish between internal and external linking. It  
effectively tests whether an element has been the target of the link  
that was followed most recently.


#some_name:target {
   background: #ffd;
   color: #000;
   outline: solid #333 2px;

Yucca, http://www.cs.tut.fi/~jkorpela/

Site Timeline