Search these areas:
Support Forums
Product Info

-DataWeb: What's New
-Creating an Application
-The DataWeb Designer
-Application Management
-Data Tables
-Data Tables
-Data Analysis
-Object Model
-Full-Text Search
-Domain and Email Hosting
-HotBlock Modules
-Account Management
-New Responsive UI Module

DataWeb Help
Support Forums
Script Library
Knowledge Base

Home > Support

Support Forum

Action button click always leaves the current page?
jennifer asked:
On my main view, I have an action button that is supposed to pop up a small window with totals when clicked. I set the href of the button to "". When I click on the action button, the popup window shows up, but the main window moves on to a new page with the "" as the URL and "[object]" as the only text on the page. Is there any way to keep the old window from moving to this new page?
Using just javascript & HTML, setting href="#" and onclick=" seems to work for a link (<a>) tag, but not for the ws:action tag.
  jimbov responded:
  Currently there isn't any way to specify an emittable onclick attribute for the <ws:action> tag. <ws:action> processing will this attribute. If you really need a button and a link won't do it for you, try adding some inline HTML to your <ws:actionbar>:

<input type="button" onclick="" name="whatever" value="open window"/>
  jimbov responded:
  Probably obvious but that last response is missing "ignore" as in "<ws:action processing will _ignore_ this attribute"  
  brendanx responded:
  Well, buttons don't have href's so maybe you are talking about a link?

Frequently in such situations, to avoid having the browser actually navigate, you must return "false" from the handle.  So your code might just work, if you change it to:

"; return false;"

For links, I tend to use a bogus href, and an onclick handler:

<a href="/" onclick="; return false;">

This definitly works on Netscape and IE.
  dougl responded:
  DataWeb considers this issue closed.
If you have additional questions or comments about this issue, please open it again.
If you have questions about a different topic please open a new support question.

DataWeb Support
  Please Log On
or create your own DataWeb Account.
Affiliate | Partner | Terms of Use | Privacy Policy | Contact Us | Pricing | Bring DataWeb In-House    
DataWeb, 720 North 10th Street, A #145, Renton, Washington 98057 *425-583-5970* Fax 484-770-4706* Email Us