Click here to Skip to main content
15,922,166 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am not able to hide or remove anchor text

<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
    <script type="text/javascript">
        $(document).ready(function () {
             $("a:contains('go to google')").remove();
        });
       
    </script>


<a href="http://google.com">go to google</a>
Posted
Comments
Kornfeld Eliyahu Peter 29-Dec-14 7:46am    
I can't see the problem...You may elaborate about it?
(See the jsFiddle that shows that your code workrs: http://jsfiddle.net/8aj86nh9/)
[no name] 29-Dec-14 7:49am    
Thanks it came :)
Thanks7872 29-Dec-14 8:16am    
Why not to hide it? Because without text, hyper link is of no use.

1 solution

this might help you ...
find-one-a-tag-and-remove-text[^]
 
Share this answer
 
Comments
[no name] 29-Dec-14 7:42am    
The link which u have given is not helpful :(

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900