• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 343
  • Last Modified:

High-Lighting the href tag that was Clicked Last in DataList in .Net

Hi Team,

I want to highlight href tag when I click it. As of now I am able to highlight it on mouse over but in order to keep it highlighted what I can do ?

In the below code I am using "categoryID" as href, on mouse over I can make it highlighted but after click how can I keep it highlighted ?

<div class="leftlinkpan">
                        Projects Category
                            <asp:DataList ID="DlProject1" runat="server" RepeatColumns="1" RepeatDirection="Horizontal"
                                        <a href='Project3.aspx?categoryID=<%#Eval("categoryID")%>' class="active">

 Looking forward to hearing from you.
  • 2
1 Solution
deepu chandranCommented:
            $("a").click(function () {
                $(this).css("color", "red");
                $(this).css("background-color", "yellow");
satmishaAuthor Commented:
I'll appreciate if you could provide some exaple/code. I tried above one but couldn't get the success.
satmishaAuthor Commented:
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now