http://www.gatewayorlando.com/conten...yRateSheet.asp
Features a list of destinations which when clicked will load a several
session variables and then redirect to a reservation request form. This
particular example uses a JavaScript function tied to the onClick event
for each TR.
onClick="trOnClick('38','20');"
function trOnClick(orgKey, destKey)
{
document.frmResortRateSheet.dropOffLocation.value = _
document.getElementById('destText' + destKey).innerHTML;
document.frmResortRateSheet.action = _
'../processingScripts/reservationRequestV3_loadTransfer.asp?org=' +
orgKey + '&dest=' + destKey;
document.frmResortRateSheet.submit();
}
The example above involves a form and changing the form's action before
submitting the form using code. An alternative would be to simply call
the page directly.
function trOnClick(destKey)
{
window.location.href='../processingScripts/rateQuoteSearch_setLocation.asp?location='
+ destKey
}
You could of course just set the onClick event to "window.location.href...".
David H
www.gatewayorlando.com
Keith wrote:
I have a list of items drawn from a SQL DB and listed on an ASP page. This
works fine.
How can I make it so that when a user clicks a particular item, a session
variable is set to the ID of the item and the user redirected to another
page?
Thanks