If:
Then:
declare extern ErrMsg,ErrReturn,OutFile
If:
Then:
declare extern UName,Pass,Remember
If:
Then:
declare OHandle(4,.0),Msg,IHandle(4,.0),SelfURL,Style,Pre
If:
Then:
IHandle=open("flfss.styleurl","r")
If:
Then:
ln=readline(IHandle,Style,"999")
If:
Then:
ln=close(Ihandle)
If:
Then:
IHandle=open("flfss.baseurl","r")
If:
IHandle lt "0"
Then:
SelfURL="/~fairlite/cgi-bin/cgiwrap/filepro/onegate";goto
skiprd2
If:
Then:
ln=readline(IHandle,SelfURL,"999")
If:
Then:
ln=close(IHandle)
If:
Then:
OHandle=open(OutFile,"wc0t")
If:
Then:
Msg="<html><head><title>User Login</title>"
If:
Style ne ""
Then:
Msg="<link rel=\"stylesheet\" href=\""{Style{"\" type=\"text/css\">"
If:
Then:
Msg="</head><body>"
If:
Then:
Msg="<div class=\"whole\"><div class=\"header\"><div class=\"title\"><h2>User Login</h2></div><br><hr></div>"
If:
Then:
Msg="<div class=\"main\">"
If:
ErrMsg ne ""
Then:
Msg="<div class=\"error\">"{ErrMsg{"</div>";gosub
sendln
If:
Then:
Msg="<br><b>If you have not registered already, you must</b>"
If:
Then:
Msg=Msg<"<a href=\""{SelfURL{"?onegate_set=flfss_create_account&username=&first_name="
If:
Then:
Msg=Msg{"&last_name=&email=&password=&verify_password=&home_url=&remember=\">Click Here</a> <b>to register first!</b>"
If:
Then:
Msg=Msg{"<br><br>";gosub
sendln
If:
Then:
Msg="<form method=\"post\" action=\""{SelfURL{"\" enctype=\"multipart/form-data\">"
If:
Then:
Msg="<input type=\"hidden\" name=\"onegate_set\" value=\"flfss_login\">"
If:
Then:
Pre="<div><div class=\"flabel\">Username:</div>"
If:
Then:
Msg="<div class=\"fval\"><input type=\"text\" size=\"15\" maxlength=\"12\" name=\"username\" value=\""{UName{"\">"
If:
Then:
Msg="</div><br><br></div>"
If:
Then:
Pre="<div><div class=\"flabel\">Password:</div>"
If:
Then:
Msg="<div class=\"fval\"><input type=\"password\" size=\"25\" maxlength=\"20\" name=\"password\">"
If:
Then:
Msg="</div><br><br></div>"
If:
Then:
Pre="<div><div class=\"flabel\">Remember Me:</div>"
If:
Remember eq "Y"
Then:
rm=" CHECKED"
If:
Then:
Msg="<div class=\"fval\"><input type=\"checkbox\" name=\"remember\" value=\"Y\""{rm{"></div><br><br></div>"
If:
Then:
Pre="<div><div class=\"flabel\"> </div>"
If:
Then:
Msg="<div class=\"fval\"><input type=\"submit\" name=\"submit\" value=\"Login!\"></div><br><br></div>"
If:
Then:
Msg="</div><div class=\"footer\"><hr><span class=\"genby\">Fairlight File Sharing System</span></div></div>"
If:
Then:
Msg="</body></html>"
If:
Then:
ln=close(OHandle)
If:
Then:
ErrReturn="DONE";end
If:
Pre ne ""
Then:
ln=writeline(OHandle,Pre,len(Pre))
If:
Msg ne ""
Then:
ln=writeline(OHandle,Msg,len(Msg))