fixed bug in posting Find forms

This commit is contained in:
Eric J. Bowersox
2002-01-19 01:28:51 +00:00
parent 18c8a5ace1
commit f68066d5e3
2 changed files with 50 additions and 41 deletions

View File

@@ -10,7 +10,7 @@
//
// The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
// for Silverwrist Design Studios. Portions created by Eric J. Bowersox are
// Copyright (C) 2001 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
// Copyright (C) 2001-02 Eric J. Bowersox/Silverwrist Design Studios. All Rights Reserved.
//
// Contributor(s):
@@ -66,7 +66,10 @@ view.offset = rinput.getParameterInt("ofs",0);
view.findCount = rinput.getParameterInt("fcount",-1);
// Adjust the search return offset based on the command button click.
if (rinput.isImageButtonClicked("search"))
// EJB 1/18/2002 - N.B.: some browsers can POST the "Search" form without triggering the
// "Search" button (by just pressing Enter), so we include the hidden "newsearch" parameter
// to distinguish between the two
if (rinput.isImageButtonClicked("search") || (rinput.getParameterInt("newsearch",0)==1))
view.offset = 0;
else if (rinput.isImageButtonClicked("previous"))
view.offset = Math.max(view.offset - view.maxResults,0); // go backwards