If:
Then:
declare global ErrMsg,ErrReturn(8,*),OutFile(256,*),FString,FileID,UpRestrict(1,YESNO),TypeFile(256,*),MimeType
If:
Then:
declare global UName,Pass,FName,LName,Email,URL,SessID,Expire,SIDString,PEncode,SessUName,FileRoot,UpOwner(12,ALLUP)
If:
Then:
declare global UpReal,UpOrig,UpSize,UpDest,UpBase,RmBase,SUpdate(1,YESNO),Deleted(1,YESNO),UpPass,OUpPass
If:
cp ne "0"
Then:
CLUName=mid(Cookie,"1",cp-"1");CLPass=mid(Cookie,cp+"1",len(Cookie)-cp);PEncode=CLPass
If:
(SessID eq "" or SessID eq "NOSESSION") and Cookie eq ""
Then:
ErrMsg="Your session has expired. Please log in again.";call "loginform";exit
If:
SessID eq "CHANGEDIP"
Then:
ErrMsg="Your session ID does not match your IP Address.";call "loginform";exit
If:
(SessID eq "" or SessID eq "NOSESSION") and Cookie eq ""
Then:
ErrMsg="Your session has expired. Please log in again.";call "loginform";exit
If:
(SessID eq "" or SessID eq "NOSESSION") and (Cookie ne "" and PEncode eq Pass)
Then:
UName=CLUname;SIDString=@PW;call "make_sessionid";SessID=SIDString;UName=CLUName;call "insert_session";SUpdate="N"
If:
Then:
UpOrig=downfl(2);UpDest=downfl(3);UpSize=downfl(4);UpRestrict=downfl(8);Deleted=downfl(10)
If:
Deleted eq "Y" and UpOwner ne UName
Then:
close downfl;ErrMsg="File does not exist.";call "logindone";exit
If:
UpRestrict eq "Y" and UpPass ne OUpPass
Then:
close downfl;ErrMsg="Password `incorrect. File access denied.";call "downpassform";exit
If:
UpRestrict eq "Y" and PassThru ne "Y"
Then:
close downfl;PassThru="Y";call "downpassthru";exit
If:
FPos lt UpSize and ln eq "0"
Then:
ErrMsg="Premature end of file during copy.";call "logindone";exit
If:
lo ne ln
Then:
ErrMsg="Could not write entire line to file during copy.";call "logindone";exit