Note that there are some explanatory texts on larger screens.

plurals
  1. POhighlight page link when on page- a:active?
    primarykey
    data
    text
    <p>I have a portfolio page with a list of clients which when clicked on will display the corresponding gallery- all of this happens on the same page. I would like for the client name to be highlighted when the corresponding gallery is shown. I thought a:active would work, but so far isn't. Any ideas? (If it matters, I'm using Wordpress.)</p> <p><a href="http://urbanpalate.com/instyle-mag-ming-by-mango/" rel="nofollow">live site</a></p> <p><code>.active { border: 1px solid #ff893b; } </code></p> <pre><code>&lt;div id="client-list"&gt; &lt;p&gt; &lt;a href="?page_id=24" &lt;?php if ($_get['page_id']=='24'){echo 'class="active"';} ?&gt; &gt;H&amp;auml;agen Dazs&lt;/a&gt;&lt;br/&gt; &lt;a href="?page_id=26" &lt;?php if ($_get['page_id']=='26'){echo 'class="active"';} ?&gt;&gt;Hugo Boss Rodeo Drive&lt;/a&gt;&lt;br/&gt; &lt;a href="?page_id=28" &lt;?php if ($_get['page_id']=='28'){echo 'class="active"';} ?&gt;&gt;Ford&lt;/a&gt;&lt;br/&gt; &lt;a href="?page_id=30" &lt;?php if ($_get['page_id']=='30'){echo 'class="active"';} ?&gt;&gt;MOCA Contemporaries&lt;/a&gt;&lt;br/&gt; &lt;a href="?page_id=32" &lt;?php if ($_get['page_id']=='32'){echo 'class="active"';} ?&gt;&gt;XBOX 360 Halo 3 Sneak Preview&lt;/a&gt;&lt;br/&gt; &lt;a href="?page_id=34" &lt;?php if ($_get['page_id']=='34'){echo 'class="active"';} ?&gt;&gt;Saddlerock Smith &amp;amp; Basso Weddings&lt;/a&gt;&lt;br/&gt; &lt;a href="?page_id=36" &lt;?php if ($_get['page_id']=='36'){echo 'class="active"';} ?&gt;&gt;Christie&amp;apos;s&lt;/a&gt;&lt;br/&gt; &lt;a href="?page_id=42" &lt;?php if ($_get['page_id']=='42'){echo 'class="active"';} ?&gt;&gt;Instyle Magazine + Ming by Mango&lt;/a&gt;&lt;/p&gt; &lt;script type="text/javascript"&gt; $(document).ready(function(){ $('a').click(function(){ $('a').removeClass('active'); $(this).addClass('active'); }); }); &lt;/script&gt; &lt;/div&gt;&lt;!-- end client-list --&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload