<% dim intDisplayTypeId dim strDisplayTypeCodePath 'set the CurrentURL with the current URL value (so the file called by the Server.Transfer method has access to it) Session("CurrentURL") = strCurrentURL 'get the display type id into the intDisplayTypeId variable intDisplayTypeId = GetDisplayType(Session("CurrentURL")) 'get the path to the include file containing the code for the related display type strDisplayTypeCodePath = GetDisplayTypeCodePath(intDisplayTypeId) 'set the relevant session variables for the current url depending on its display type id Select Case intDisplayTypeId Case 1 'if display type is "Postings page (Index/Detail)" 'set the PostingId session variable with the id querystring value Session("PostingId") = Request.QueryString("id") 'set the PostingTypeId session variable with the id querystring value Session("PostingTypeId") = GetPostingTypeId(strCurrentURL) Case 2 'if display type is "Postings page (Index with Year Menu/Detail)" 'set the PostingYear session variable with the year querystring value Session("PostingYear") = Request.QueryString("year") 'set the PostingId session variable with the id querystring value Session("PostingId") = Request.QueryString("id") 'set the PostingTypeId session variable with the id querystring value Session("PostingTypeId") = GetPostingTypeId(Session("CurrentURL")) Case 3 'if display type is "Postings page (Index with Month and Year Menu/Detail)" 'set the PostingYear session variable with the year querystring value Session("PostingYear") = Request.QueryString("year") 'set the PostingYear session variable with the year querystring value Session("PostingMonth") = Request.QueryString("month") 'set the PostingId session variable with the id querystring value Session("PostingId") = Request.QueryString("id") 'set the PostingTypeId session variable with the id querystring value Session("PostingTypeId") = GetPostingTypeId(strCurrentURL) Case 4 'if display type is "Dynamic Text and Images" 'only requires the CurrentURL session variable which is already set Case 5 'if display type is "Email Subscription Form" 'set the UserIsSubscribedStatus session variable with the subscribed querystring value Session("UserIsSubscribedStatus") = Request.Querystring("subscribed") Case 6 'if display type is "Search Form" 'set the SearchString session variable with the txtSearchString form element value Session("SearchString") = Trim(Request.Form("txtSearchString")) 'Case 7 'if display type is "Static Text and Images" 'not required since the content is hard coded in the current page Case 8 'if display type is "Site Map" Case 9 'if display type is "Contact Us Form" 'set the ContactUsFirstName session variable with the user requesting information's first name Session("ContactUsFirstName") = Request.Form("txtFirstName") 'set the ContactUsLastName session variable with the user requesting information's last name Session("ContactUsLastName") = Request.Form("txtLastName") 'set the ContactUsOrganization session variable with the user requesting information's organization name Session("ContactUsOrganization") = Request.Form("txtOrganization") 'set the ContactUsDescription session variable with the user requesting information's description of request name Session("ContactUsDescription") = Request.Form("txtDescription") 'set the ContactUsEmail session variable with the user requesting information's email address Session("ContactUsEmail") = Request.Form("txtEmail") 'set the ContactUsWishesToSubscribe session variable with the boolean value of the user wishing to subscribe or not Session("ContactUsWishesToSubscribe") = CBool(Request.Form("chkSubscribe")) Case 13 'if display type is "Dynamic Form" then... 'set the PostingTypeId session variable with the id querystring value Session("DynamicFormId") = GetURLDynamicFormId(strCurrentURL) End Select 'display the dynamic content Server.Execute(strDisplayTypeCodePath) 'set all session variables with an empty string Session("CurrentURL") = "" Session("PostingMonth") = "" Session("PostingYear") = "" Session("PostingId") = "" Session("SearchString") = "" Session("PostingTypeId") = "" Session("UserIsSubscribedStatus") = "" Session("ContactUsFirstName") = "" Session("ContactUsLastName") = "" Session("ContactUsOrganization") = "" Session("ContactUsDescription") = "" Session("ContactUsEmail") = "" %>