Connecting Tech Pros Worldwide Help | Site Map

OnChange=submit(); command flips parent page...

 
LinkBack Thread Tools Search this Thread
  #1  
Old July 23rd, 2005, 10:44 AM
Mel
Guest
 
Posts: n/a
Default OnChange=submit(); command flips parent page...

i popup a new window in my submit command and return false;

but my parent still flips the page ! how can i stop it ?

thanks



  #2  
Old July 23rd, 2005, 10:44 AM
Michael Winter
Guest
 
Posts: n/a
Default Re: OnChange=submit(); command flips parent page...

On Wed, 5 May 2004 13:12:18 -0400, Mel <mehra.heravi@ssa.gov> wrote:
[color=blue]
> i popup a new window in my submit command and return false;
>
> but my parent still flips the page ! how can i stop it ?[/color]

Your code?

By the way, you should never perform an action like submitting a form or
navigating a page based on changing a value. Only do it from activating a
button or link: something they expect.

Users can make mistakes. Allow them to fix them.

Mike

--
Michael Winter
M.Winter@blueyonder.co.invalid (replace ".invalid" with ".uk" to reply)
  #3  
Old July 23rd, 2005, 10:44 AM
Lasse Reichstein Nielsen
Guest
 
Posts: n/a
Default Re: OnChange=submit(); command flips parent page...

"Mel" <mehra.heravi@ssa.gov> writes:
[color=blue]
> i popup a new window in my submit command and return false;
>
> but my parent still flips the page ! how can i stop it ?[/color]

Calling the submit function bypasses the onsubmit handler. The handler
is only called if the user submits the form (using as submit button or
pressing return in an appropriate field).

You should almost never submit a page when a value is changed. It is a
usability problem for normal people making a mistake and, if used on
select elements, impossible to use for people navigating with the
keyboard (which some people are forced to do).

/L
--
Lasse Reichstein Nielsen - lrn@hotpop.com
DHTML Death Colors: <URL:http://www.infimum.dk/HTML/rasterTriangleDOM.html>
'Faith without judgement merely degrades the spirit divine.'
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,989 network members.