Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

disable javascript for browser

 
lily zou
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a html page which has a image button. OnClick action on that button will envoke a javascript function to open a window if javascript is enabled by browser. The same contents will be displayed in main window if browser is not supporting javascript.
However, when I click the button, the contents gets displayed both in popup window and main window.
It worked fine so far. May I ask if any one has idea about why browser goes crazy and execute both of them?
Thanks a lot,
Lily
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well I need to see the code that you are using in order to show you want the problem is.
 
lily zou
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
this is the html code got by "view source":
[a href="ABC" [onclick]="showHelpMenu('ABC'); return false"][img border="0" src="./images/en/help.gif" alt="Help" ][a]
It worked fine so far but all the sudden......
 
lily zou
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I used [ and ] in some places since I can not use html code as it is. the [ and ] around onclik is for the same reason
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
<a href="ABC" onclick="showHelpMenu(this.href); return false"><img border="0" src="./images/en/help.gif" alt="Help"></a>
See if that helps...
I have to run to work, so I can not think of any other solution, even thought I think there is one.

Eric
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic