aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes Disable a Link Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Disable a Link" Watch "Disable a Link" New topic
Author

Disable a Link

preethi venkatarangan
Greenhorn

Joined: Jan 21, 2007
Posts: 27
Hi..
I have a href link which is an image & when you click on the image it opens a new browser.now how do i disable &gray out the link after it is clicked once so that it doesnt open a new window/browser again.
[CODE] <a href="javascript:clickLink();"><img align="middle" src="online.gif" border="0"></a>
function clickLink()
{
document.logon.submit();
Thanks
Preethi}
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
clickLink();this.href='javascript:void(0);'

Eric
 
 
subject: Disable a Link