home *** CD-ROM | disk | FTP | other *** search
/ Chip 1998 February / CHIP_2_98.iso / software / pelne / optionp / iis4_03.cab / iidoc.asp < prev    next >
Text File  |  1997-11-12  |  4KB  |  159 lines

  1. <%@ LANGUAGE=VBScript %>
  2. <% Option Explicit %>
  3. <% Response.Expires = 0 %>
  4.  
  5. <% if Session("FONTSIZE") = "" then %>
  6.     <!--#include file="iito.inc"-->
  7. <% else %>
  8.  
  9. <% 
  10. Const L_DOCUMENTS_TEXT="Documents"
  11. Const L_ENABLEDEFAULT_TEXT="Enable default document"
  12. Const L_MULTIDOC_TEXT="Multiple documents may be entered in a comma separated list."
  13. Const L_DEFAULTDOC_TEXT="Default document name:"
  14. Const L_ENABLEDOCFOOTER_TEXT="Enable document footer"
  15. Const L_DOCFOOTER_TEXT="Document footer path:" 
  16. Const L_PERFORMANCE_WARNINGMESSAGE="PERFORMANCE WARNING!\r\rDocument footers provide an easy way to have the same \rcontent appear on the bottom of each page, however on a \rheavily accessed server, this could cause performance \rdegradation. \r\rAre you sure you want to use Document Footer?"
  17. Const L_BROWSE_TEXT = "Browse..."
  18.  
  19. On Error Resume Next 
  20.  
  21. Dim path, currentobj
  22.  
  23. path=Session("dpath")
  24. Session("path")=path
  25. Session("SpecObj")=""
  26. Session("SpecProps")=""
  27. Set currentobj=GetObject(path)
  28.  %>
  29.  
  30. <!--#include file="iiset.inc"-->
  31.  
  32. <HTML>
  33. <HEAD>
  34.  
  35. <SCRIPT LANGUAGE="JavaScript">
  36.  
  37.     top.title.Global.helpFileName="iipy_36";
  38.     top.title.Global.siteProperties = false;
  39.     function disableDefault(dir,fromCntrl, toCntrl){
  40.         if (!dir){
  41.             if (fromCntrl.value !=""){
  42.                 toCntrl.value=fromCntrl.value;
  43.                 fromCntrl.value="";
  44.             }
  45.         }
  46.         else{
  47.             if (toCntrl.value !=""){
  48.                 fromCntrl.value=toCntrl.value;
  49.                 toCntrl.value="";
  50.             }
  51.         }
  52.     }
  53.  
  54.     function enableDefault(textcntrl, chkCntrl){
  55.         if (textcntrl.value !=""){
  56.             chkCntrl.checked=true;
  57.         }
  58.         else{
  59.             chkCntrl.checked=false;
  60.         }
  61.     }
  62.  
  63.     function warn(){
  64.         top.title.Global.working = true;
  65.         if (document.userform.chkEnableDocFooter.checked) {
  66.             if (confirm("<%= L_PERFORMANCE_WARNINGMESSAGE %>")){
  67.                 document.userform.chkEnableDocFooter.checked=true;
  68.             }
  69.             else{
  70.                 document.userform.chkEnableDocFooter.checked=false;
  71.                 document.userform.DefaultDocFooter.value="";
  72.             }
  73.  
  74.         }
  75.         top.title.Global.working = false;
  76.     }
  77.     
  78.     function chkPath(pathCntrl){
  79.         if (pathCntrl.value != ""){
  80.             top.connect.location.href = "iichkpath.asp?path=" + escape(pathCntrl.value) + "&ptype=1";            
  81.         }
  82.     }
  83.     
  84. </SCRIPT>
  85.  
  86.  
  87.  
  88. <% if Session("canBrowse") then %>
  89. <SCRIPT SRC="JSBrowser/JSBrowser.js">
  90. </SCRIPT>
  91. <SCRIPT>
  92. function popBrowser()
  93. {
  94.     JSBrowser = new BrowserObj(document.userform.DefaultDocFooter,true,TFILE,<%= Session("FONTSIZE") %>);
  95. }
  96. </SCRIPT>
  97.  
  98.  
  99.  
  100.  
  101. <% end if %>
  102.  
  103. </HEAD>
  104.  
  105. <BODY BGCOLOR="#CCCCCC" TOPMARGIN=5 TEXT="#000000" LINK="#FFFFFF" STYLE="font-face: Helv,Arial; font-size:10pt;">
  106.  
  107. <FONT SIZE=1 FACE="Helv,Arial">
  108. <B><%= L_DOCUMENTS_TEXT %></B>
  109.  
  110. <FORM NAME="userform">
  111. <FONT SIZE=1 FACE="Helv,Arial">
  112. <INPUT TYPE="hidden" NAME="page" VALUE="iidoc">
  113.     <%= checkbox("EnableDefaultDoc","disableDefault(this.checked,document.userform.DefaultDoc, document.userform.hdnDefaultDoc);",false) %>        
  114.         <%= L_ENABLEDEFAULT_TEXT %>
  115.     <P>
  116.     <%= L_MULTIDOC_TEXT %>    
  117. </FONT>
  118. <BLOCKQUOTE>
  119. <TABLE>
  120. <TR>
  121.     <TD WIDTH=150>
  122.         <FONT SIZE=1 FACE="Helv,Arial"><%= L_DEFAULTDOC_TEXT %> </FONT>
  123.     </TD>
  124.     <TD><FONT SIZE=1 FACE="Helv,Arial">
  125.         <%= text("DefaultDoc",50,"enableDefault(this,document.userform.chkEnableDefaultDoc);" ,"","",true,false) %>
  126.     </TD>
  127. </TR>
  128. </TABLE>
  129. </BLOCKQUOTE>
  130. <HR>
  131.     <%= checkbox("EnableDocFooter","disableDefault(this.checked,document.userform.DefaultDocFooter, document.userform.hdnDefaultDocFooter);warn();",false) %>        
  132.             <FONT SIZE=1 FACE="Helv,Arial">
  133.                 <%= L_ENABLEDOCFOOTER_TEXT %>
  134.             </FONT>
  135.  
  136. <BLOCKQUOTE>
  137. <TABLE>
  138. <TR>
  139.     <TD WIDTH=150 VALIGN="top">
  140.         <FONT SIZE=1 FACE="Helv,Arial"><%= L_DOCFOOTER_TEXT %>    </FONT>
  141.     </TD>
  142.     <TD VALIGN="top"><FONT SIZE=1 FACE="Helv,Arial">
  143.         <%= text("DefaultDocFooter",50,"enableDefault(this, document.userform.chkEnableDocFooter);chkPath(this);" ,"","",true,false) %>
  144.         <P ALIGN="right">
  145. <% if Session("canBrowse") then %>        
  146.         <INPUT TYPE="button" NAME="hdnBrower" VALUE="<%= L_BROWSE_TEXT %>" OnClick="popBrowser();">
  147. <% end if %>
  148.     </TD>
  149. </TR>
  150. </TABLE>
  151. </BLOCKQUOTE>
  152.  
  153. </FONT>
  154.  
  155. </FORM>
  156. </BODY>
  157.  
  158. </HTML>
  159. <% end if %>