home *** CD-ROM | disk | FTP | other *** search
- <%
- #include </utility/security.fts>
- #include </utility/global.fts>
- #include </utility/theme.fts>
- #include </utility/ftgate.fts>
-
- var s = new server.system
-
- var entries
- var refresh
- var direction=0
-
- if (form.config=="1")
- {
- refresh = form.refresh
- entries = form.entries
- }
- else
- {
- if (request.entries>0)
- {
- entries = request.entries
- refresh = request.refresh
- direction = request.direction
- }
- }
-
- if (entries<=0)
- entries=100
- %>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
- <HTML>
- <HEAD>
- <META NAME="GENERATOR" Content="Microsoft Developer Studio">
- <META HTTP-EQUIV="Content-Type" content="text/html; charset=iso-8859-1">
- <TITLE>FTGate Administration</TITLE>
- <LINK REL=STYLESHEET HREF="/utility/main<%=nn4%>.css" TYPE="text/css">
- <STYLE>
- BODY { margin: 0; padding: 0; border: 0 }
- FORM { margin: 0; padding: 0; border: 0 }
- </STYLE>
- <SCRIPT LANGUAGE="JavaScript1.2" SRC="/utility/time.js" TYPE="text/javascript"></SCRIPT>
- <SCRIPT LANGUAGE="JavaScript1.2" TYPE="text/javascript">
- <!--
- var dir="<%=buttons%>";
- var direction=<%=direction%>;
-
- <%
- if (netscape)
- {
- %>
- document.captureEvents(Event.KEYPRESS);
- document.onkeypress = keypress;
-
- function keypress(event)
- {
- if (event.which==13)
- {
- onEntries();
- return false;
- }
-
- return true;
- }
- <%
- }
- else
- {
- %>
- function keypress()
- {
- if (event.keyCode==13)
- {
- event.returnValue=null;
- onEntries();
- }
- }
- <%
- }
- %>
-
- if (!document.images) {}
- else {
- up0 = new Image();
- up0.src = dir+"up.gif";
- up1 = new Image();
- up1.src = dir+"upon.gif";
- down0 = new Image();
- down0.src = dir+"down.gif";
- down1 = new Image();
- down1.src = dir+"downon.gif";
- refresh0 = new Image();
- refresh0.src = dir+"refresh.gif";
- refresh1 = new Image();
- refresh1.src = dir+"refreshon.gif";
- clear0 = new Image();
- clear0.src = dir+"delete.gif";
- clear1 = new Image();
- clear1.src = dir+"deleteon.gif";
- }
-
- function change(Name,Image,No)
- {
- if (!document.images) {}
- else document [Name].src = eval(Image + No + ".src");
- }
-
- function resetRadios()
- {
- if (direction==1)
- {
- change('upA', 'up', 1);
- change('downA', 'down', 0);
- }
- else
- {
- change('upA', 'up', 0);
- change('downA', 'down', 1);
- }
- }
-
- function onDirection(dir)
- {
- var secs;
-
- if (!isOK())
- {
- resetRadios();
-
- return;
- }
-
- direction=dir;
-
- resetRadios();
-
- secs = fromNicePeriod(document.ftgate.refresh.value);
- parent.log.location.href="log.fts?direction="+direction+
- "&entries="+document.ftgate.entries.value+
- "&refresh="+secs;
- }
-
- function onEntries()
- {
- var secs;
-
- change('refreshA','refresh',0);
-
- if (!isOK())
- return;
-
- secs = fromNicePeriod(document.ftgate.refresh.value);
- parent.log.location.href="log.fts?direction="+direction+
- "&entries="+document.ftgate.entries.value+
- "&refresh="+secs;
- }
-
- function onClear()
- {
- change('clearA','clear',0);
-
- if (!isOK())
- return;
-
- secs = fromNicePeriod(document.ftgate.refresh.value);
- parent.log.location.href="log.fts?direction="+direction+
- "&entries="+document.ftgate.entries.value+
- "&refresh="+secs+
- "&clear=1";
- }
-
- function isOK()
- {
- var entries = document.ftgate.entries.value;
-
- if (entries<=0)
- {
- alert("Enter a value greater than zero.");
- document.ftgate.entries.focus();
-
- return false;
- }
-
- if (entries>100)
- {
- alert("Enter a value less than or equal to 100.");
- document.ftgate.entries.focus();
-
- return false;
- }
-
- if (!isPeriod(document.ftgate.refresh.value))
- {
- window.alert("Enter a valid time period.");
- document.ftgate.refresh.focus();
- return false;
- }
-
- return true;
- }
-
- function onLoad()
- {
- parent.log.location.href="log.fts?entries=<%=entries%>&direction=<%=direction%>";
- document.ftgate.refresh.value = toNicePeriod(<%=refresh%>);
- document.ftgate.entries.focus();
- }
-
- //-->
- </SCRIPT>
- </HEAD>
-
- <BODY BGCOLOR="<%=body%>" onLoad="onLoad()" onkeypress="keypress()">
- <FORM NAME="ftgate" onSubmit="return isOK()" METHOD="POST" ACTION="">
- <INPUT TYPE="HIDDEN" NAME="config" VALUE="1">
- <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" WIDTh="100%">
- <TR>
- <TD WIDTH="1%"><IMG SRC="/images/<%=s.serverid%>1.gif" VSPACE="0" ALT="<%=s.serverid%>" WIDTH="200" HEIGHT="54"></TD>
- <TD VALIGN="CENTER" ALIGN="RIGHT">
- <%
- if (direction==1)
- {
- %>
- <A onMouseDown="change('downA', 'down', 1)" onMouseOut="resetRadios()" HREF="javascript:onDirection(0)"><IMG SRC="<%=buttons%>down.gif" WIDTH="20" HEIGHT="20" NAME="downA" BORDER="0" ALT="Oldest first"></A>
- <A onMouseDown="change('upA', 'up', 1)" onMouseOut="resetRadios()" HREF="javascript:onDirection(1)"><IMG SRC="<%=buttons%>upon.gif" WIDTH="20" HEIGHT="20" NAME="upA" BORDER="0" ALT="Newest first"></A>
- <%
- }
- else
- {
- %>
- <A onMouseDown="change('downA', 'down', 1)" onMouseOut="resetRadios()" HREF="javascript:onDirection(0)"><IMG SRC="<%=buttons%>downon.gif" WIDTH="20" HEIGHT="20" NAME="downA" BORDER="0" ALT="Oldest first"></A>
- <A onMouseDown="change('upA', 'up', 1)" onMouseOut="resetRadios()" HREF="javascript:onDirection(1)"><IMG SRC="<%=buttons%>up.gif" WIDTH="20" HEIGHT="20" NAME="upA" BORDER="0" ALT="Newest first"></A>
- <%
- }
- %>
- <A onMouseDown="change('refreshA','refresh',1)" onMouseOut="change('refreshA','refresh',0)" HREF="javascript:onEntries()"><IMG SRC="<%=buttons%>refresh.gif" WIDTH="20" HEIGHT="20" NAME="refreshA" BORDER="0" ALT="Refresh Log"></A>
- </TD>
- <TD VALIGN="CENTER">
- List last <INPUT TYPE="EDIT" NAME="entries" SIZE="<%=size5%>" VALUE="<%=entries%>"> entries.
- </TD>
- <TD VALIGN="CENTER">
- Refresh every <INPUT TYPE="EDIT" NAME="refresh" SIZE="<%=size5%>" VALUE="<%=refresh%>">
- </TD>
- </TR>
- </TABLE>
- </FORM>
- </BODY>
- </HTML>