[thelist] Tough querystring problem!

Mark Marlow mark at testwiz.com
Wed Mar 16 08:28:25 CST 2005


To paraphrase your requirement:

Main page opens report page in new window by passing a date argument.
Report page is displayed.
User clicks hyperlinks in column heading to request a sorted report page.

Solution 1:
Append any data required for page to refresh to the hyperlinks used to sort
during ASP processing. E.g.
Href="report.asp?sortdir=asc&sortcol=company&date=010105&option=x&start=y&en
d=z".  Any variables in the get string will be available on the server side.

Solution 2:
Keep values in hidden form variables during ASP processing.  A javascript
method called from  each columns <a
href="javascript:sort('sales','up')">+</a> would have parameters to indicate
the column and direction. The sort() function would update a pair of hidden
variables "SortColumn" "SortDirection" appropriately, then call the form's
submit method. Any data stored in the hidden variables will be available on
the Server side.

Solution 2 involves client side scripting, thus is a bit more risky.  Keep
in mind that depending on the values of the arguments you pass around, you
might have to URL encode them.
- Mark





More information about the thelist mailing list