Friday, April 5, 2013

toggle anchor tag text on click of anchor

toggle anchor tag text on click of anchor


 id="reply" href="#">reply

$("#reply").click(function() {
   ($(this).text() === "reply") ? $(this).text("close") : $(this).text("reply");
});

JS FIDDLE LINK 

No comments:

Post a Comment

ASP.NET Core

 Certainly! Here are 10 advanced .NET Core interview questions covering various topics: 1. **ASP.NET Core Middleware Pipeline**: Explain the...