Server.Execute Problem...

Results 1 to 2 of 2

Thread: Server.Execute Problem...

  1. #1
    Nils Kaiser Guest

    Default Server.Execute Problem...

    For my website with member section i need authorization... so i do that with session variables and it works.<BR>In my "Forbidden page" I want to save a link to the page that was called without permission, so I need to pass it through a Query String in my Server.Execute Statement like this:<BR><BR>Server.Execute("../Errors/Forbidden.asp?Adress=Members/List.asp");<BR><BR>but this doesn&#039t work... i get a server execute error.<BR>Why? Is there another way to get the adress of the page that called Server.Execute?

  2. #2
    Join Date
    Dec 1969

    Default Read the documentation...

    The MS docs for Server.Execute say, in part:<BR><BR>**** QUOTE ****<BR>Any QueryString that was available to the .asp file that calls ServerExecute will be available to the executed .asp file, so there is no need to pass the QueryString in the path parameter of Server.Execute. However, you cannot pass a different query string in the Path parameter.<BR><BR>**** END QUOTE ****<BR><BR>See that last part: " *CANNOT* pass a different query string..."<BR><BR>So you need to find another way to do this. Session values spring to mind. That&#039s not as bad as it sounds, because you could wipe out the Session collection when the Execute page returns (by doing Session.Contents.RemoveAll or Session.Contents.Remove) so there won&#039t be a persistent "hit" on memory space.<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts