Desperately need help wrapping a Class in If.. Sta

Results 1 to 2 of 2

Thread: Desperately need help wrapping a Class in If.. Sta

  1. #1
    Just. Guest

    Default Desperately need help wrapping a Class in If.. Sta

    Hi Everyone,<BR><BR>I have a problem here which I have never encountered and simply cannot solve alone. This thing is keeping me up at night now and I just cant work it out. Heres the problem:-<BR><BR>I have an index.asp page which has a whole bunch of server side includes which are loaded depending on the querystring. This part is very important that it functions within the &#039;one page&#039;.<BR><BR> One of my include files contains one of the &#039;Pure ASP upload&#039; scripts which has a class file in there.<BR>My problem is, how the hell can I wrap this file in an If..Then statement without it throwing up errors??<BR><BR>At the moment, I have stuff like this to load my SSI&#039;s:-<BR><BR>&#060;%<BR>If Request.QueryString("Type") = "Whatever" Then<BR>%&#062;<BR>&#060;!--#include my file here--&#062;<BR>&#060;%<BR>End If<BR>%&#062;<BR><BR><BR>...As soon as I wrap the file containing the class in an If statement it goes belly up such as this:-<BR><BR>Syntax error<BR>/includes/main/, line 2<BR>Class FileUpload<BR><BR>Now, I have tried changing the if statements to select case statements but theres no luck there either not that I am surprised.<BR><BR>Somebody out there MUST know how on earth I can wrap this include in an if statement!?<BR><BR>I&#039;m sure I&#039;ve tried everything to get this working and works fine as a stand alone page, but I need this operating within the index.asp page loaded from a querystring.<BR><BR>If anyone out ther can offer any views on this I would be forever grateful!<BR><BR>Thanks,<BR>Just.<BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Desperately need help wrapping a Class in If..

    Just for gits and shiggles, I added this into a page...<BR><BR>&#060;%if not Request.Form("Auth") then%&#062;<BR>&#060;!-- #INCLUDE file="../include/header.asp" --&#062;<BR>&#060;%end if%&#062;<BR><BR>It works with no problem.

Posting Permissions

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