Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

201 lines
7.7 KiB

  1. <!-- #INCLUDE VIRTUAL = "include/asp/top.asp" -->
  2. <!-- #INCLUDE VIRTUAL = "include/asp/head.asp" -->
  3. <!-- #INCLUDE VIRTUAL = "include/inc/corpcustomerstrings.inc" -->
  4. <%
  5. If (Request.Cookies("OCA")("Done") = 1) Then
  6. Response.Redirect "http://" & Request.ServerVariables("SERVER_NAME") & "/cerintro.asp"
  7. End If
  8. Dim RS
  9. Dim Count
  10. Dim Done
  11. Dim aa
  12. Dim IncidentIDs
  13. Dim Conn
  14. %>
  15. <% If (oPassMgrObj.IsAuthenticated(TimeWindow, ForceLogin)) Then %>
  16. <%
  17. Call CCreateConnection
  18. If (Request.QueryString("n") = 0) Then
  19. Response.Write "<BODY BGCOLOR=""#ffffff"" TOPMARGIN=0 LEFTMARGIN=0 MARGINHEIGHT=0 MARGINWIDTH=0>"
  20. Response.Write "<br><div class='clsDiv'><P CLASS='clsPTitle'>" & L_CERUP_NO_FILES0_TEXT & "</P>"
  21. Response.Write "<P CLASS='clsPBody'>" & L_CERUP_NO_FILES_TEXT & Request.Cookies("OCA")("Path") & "</P>"
  22. Response.Write "<P CLASS='clsPBody'><img Alt=" & L_WELCOME_GO_IMAGEALT_TEXT & " border=0 src='../include/images/go.gif' width='24' height='24'><A class='clsALink' href='https://" & Request.ServerVariables("SERVER_NAME") & "/cerintro.asp'>" & L_RECEIVED_NEWFILE_LINK_TEXT & "</a></p>"
  23. %><!-- #INCLUDE VIRTUAL = "include/asp/foot.asp" --><%
  24. Call CDestroyObjects
  25. Response.End
  26. End If
  27. If (Request.QueryString("n") > 32) Then
  28. Count = 32
  29. Done = 0
  30. Else
  31. Count = Request.QueryString("n")
  32. Done = 1
  33. End If
  34. If (Request.QueryString("f") = 1) Then
  35. Conn.Execute("SetFileCount(" & Request.QueryString("t") & "," & Request.QueryString("n") & ")")
  36. End If
  37. For aa = 1 To Count
  38. Set RS = Conn.Execute("GetIncident2(" & oPassMgrObj.Profile("MemberIdHigh") & "," & oPassMgrObj.Profile("MemberIdLow") & "," & Request.QueryString("t") & ")")
  39. If (Err.Number <> 0) Then
  40. Response.Write "<BODY BGCOLOR=""#ffffff"" TOPMARGIN=0 LEFTMARGIN=0 MARGINHEIGHT=0 MARGINWIDTH=0>"
  41. Response.Write "<br><div class='divLoad'><p class='clsPTitle'>" & L_COMMENTS_UNABLE_TOCONNECT_ERRORMESSAGE & "</p>"
  42. Response.Write "<p class='clsPBody'>" & L_COMMENTS_DATABASE_FAILED_TEXT & "</p></div>"
  43. 'Response.Write "<P CLASS='clsPBody'>" & Err.Description & "</P>"
  44. %><!-- #INCLUDE VIRTUAL = "include/asp/foot.asp" --><%
  45. Call CDestroyObjects
  46. Response.End
  47. End If
  48. If (Not RS.EOF) Then
  49. Conn.Execute("SetTrackID(" & RS("IncidentID") & ",'" & Hex(Date()) & Hex(RS("IncidentID")) & "')")
  50. IncidentIDs = IncidentIDs & RS("IncidentID") & ";"
  51. RS.Close
  52. End If
  53. Set RS = Nothing
  54. Next
  55. Response.Write "<BODY onClick=""GoWindow()"" onLoad=""UploadFiles()"">"
  56. Private Sub CCreateConnection
  57. Set Conn = Server.CreateObject("ADODB.Connection")
  58. With Conn
  59. .ConnectionString = strCustomer
  60. .CursorLocation = adUseClient
  61. .ConnectionTimeout = strGlobalConnectionTimeout
  62. .Open
  63. End With
  64. If (Err.Number <> 0) Then
  65. Response.Write "ERROR: [" & Err.Number & "]" & Err.Description
  66. Call CDestroyObjects
  67. Response.End
  68. End If
  69. End Sub
  70. Private Sub CDestroyObjects
  71. Conn.Close
  72. Set Conn = Nothing
  73. End Sub
  74. %>
  75. <br>
  76. <div class="clsDiv">
  77. <P CLASS="clsPTitle"><%=L_CERUP_TIT_LE_TEXT%></P>
  78. <P CLASS="clsPBody"><%=L_CERUP_UPLOAD_SUMMARY_TEXT%></P>
  79. <OBJECT id="Cer" name="CerUpload" viewastext UNSELECTABLE="on" style="display:none"
  80. CLASSID="clsid:35D339D5-756E-4948-860E-30B6C3B4494A"
  81. codebase="https://<%=Request.ServerVariables("SERVER_NAME")%>/secure/cerupload.cab#version=<%=strCERVersion%>" height=0 width=0>
  82. <BR>
  83. <div class="clsDiv">
  84. <P class="clsPTitle">
  85. <% = L_LOCATE_WARN_ING_ERRORMESSAGE %>
  86. </P>
  87. <p class="clsPBody">
  88. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSONE_TEXT %><BR>
  89. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSTWO_TEXT %><BR>
  90. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSTHREE_TEXT %><BR><BR>
  91. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSFOUR_TEXT %><BR>
  92. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSFIVE_TEXT %><BR>
  93. <% = L_FAQ_WHYDOIGETAMESSAGEBOX_DETAILSSIX_TEXT %><BR>
  94. </p>
  95. </div>
  96. </OBJECT>
  97. <P CLASS="clsPSubTitle"><%=L_CERUP_SUB_TITLE_TEXT%></P>
  98. <CENTER>
  99. <P CLASS="clsPBody"><%=L_CERUP_UPLOADING_BLOCK_TEXT%>&nbsp;<%=Request.QueryString("b")%></P><BR><BR>
  100. <TABLE CLASS="clsTableNormal" BORDER=0>
  101. <TR>
  102. <TD ID=FileStatus>&nbsp;</TD>
  103. </TR>
  104. </TABLE>
  105. </CENTER>
  106. <SCRIPT Language=VBScript>
  107. Dim UploadWindow
  108. Dim MyTimer
  109. Dim x
  110. x=0
  111. Function WaitUp
  112. x = x + 1
  113. If (UploadWindow.document.readystate = "complete") Then
  114. Call Upload
  115. window.clearinterval(MyTimer)
  116. End If
  117. WaitUp = True
  118. End Function
  119. Function GoWindow
  120. on error resume next
  121. If IsObject(UploadWindow) Then
  122. UploadWindow.Focus
  123. End If
  124. GoWindow = False
  125. End Function
  126. Private Sub Upload
  127. Files = CER.GetFileNames("<%=Request.QueryString("p")%>","<%=Hex(Request.QueryString("t"))%>",<%=Count%>)
  128. IDs = "<%=IncidentIDs%>"
  129. For aa = 1 To <%=Count%>
  130. File = Left(Files,InStr(1,Files,";")-1)
  131. Files = Right(Files,Len(Files) - InStr(1,Files,";"))
  132. ID = Left(IDs,InStr(1,IDs,";")-1)
  133. IDs = Right(IDs,Len(IDs) - InStr(1,IDs,";"))
  134. UploadWindow.dInfo.innerHTML = "<%=L_CERUP_UPLOAD_STATUS_TEXT1%> " & aa & " <%=L_CERUP_UPLOAD_STATUS_TEXT2%>&nbsp;&nbsp;<%=Count%>" & "&nbsp;&nbsp;<%=L_CERUP_UPLOADING_BLOCK_TEXT%>&nbsp;<%=Request.QueryString("b")%>"
  135. Result = CER.Upload1("<%=Request.QueryString("p")%>","<%=Hex(Request.QueryString("t"))%>",CStr(File),CStr(Hex(ID)),"<%=strGlobalOptionCode%>","<%=Request.Cookies("OCA")("Type")%>")
  136. If (Result <> 0) Then
  137. 'MsgBox "<%=L_CERUP_UPLOAD_ERROR_ALERT%> " & File & "<%=L_CERUP_UPLOAD_ERROR_ALERT2%>"
  138. End If
  139. Next
  140. UploadWindow.Close
  141. If (<%=Done%> = 1) Then
  142. Result = CER.EndTransaction("<%=Request.QueryString("p")%>","<%=Hex(Request.QueryString("t"))%>")
  143. FileCount = CER.GetSuccessCount("<%=Request.QueryString("p")%>","<%=Hex(Request.QueryString("t"))%>")
  144. If ("<%=Request.Cookies("OCA")("Type")%>" = "shutdown") Then
  145. Window.Location.HREF = "http://<%=Request.ServerVariables("SERVER_NAME")%>/shutdown.asp"
  146. ElseIf ("<%=Request.Cookies("OCA")("Type")%>" = "appcompat") Then
  147. Window.Location.HREF = "http://<%=Request.ServerVariables("SERVER_NAME")%>/pcw.asp"
  148. Else
  149. Window.Location.HREF = "http://<%=Request.ServerVariables("SERVER_NAME")%>/cerdone.asp?id=<%=Request.QueryString("t")%>&Count=" & FileCount
  150. End If
  151. 'FileStatus.innerHTML = "<P class='clsPTitle'><%=L_CERUP_UPLOAD_SUMMARY_TEXT%></P><P class='clsPBody'><%=L_CERUP_COM_PLETE_TEXT%></P>"
  152. Else
  153. Window.Location.HREF = "https://<%=Request.ServerVariables("SERVER_NAME")%>/secure/cerup.asp?n=<%=Request.QueryString("n") - 32%>&b=<%=(Request.QueryString("b") + 1)%>&p=<%=Request.QueryString("p")%>&t=<%=Request.QueryString("t")%>"
  154. End If
  155. End Sub
  156. Function UploadFiles
  157. Dim iHeight, iWidth, iTop, iLeft
  158. iHeight = window.screen.availHeight
  159. iWidth = window.screen.availWidth
  160. iWidth = iWidth / 2
  161. iHeight = iHeight / 3
  162. iLeft = (window.screen.width / 2) - (iWidth / 2)
  163. iTop = (window.screen.height / 2) - (iHeight / 2)
  164. Set UploadWindow = window.open("wait.asp?msg=3","UploadWindow","top=" & iTop & ",Left=" & iLeft & ",width=" & iWidth & ",height=" & iHeight & ",status=yes,toolbar=no,menubar=no")
  165. MyTimer = window.setInterval("WaitUp()",2000)
  166. 'Do while UploadWindow.document.readystate <> "complete"
  167. 'Loop
  168. UploadFiles = False
  169. End Function
  170. </SCRIPT>
  171. <% Else %>
  172. <P CLASS="clsPTitle">
  173. <%=L_CERCUST_PASSPORT_TITLE_TEXT%>
  174. </P>
  175. <P CLASS="clsPBody">
  176. <%=L_CERCUST_PASS_PORT_TEXT%>&nbsp;<A CLASS="clsALinkNormal" HREF="<%=L_FAQ_PASSPORT_LINK_TEXT%>"><%=L_WELCOME_PASSPORT_LINK_TEXT%>
  177. <BR><BR>
  178. <%=oPassMgrObj.LogoTag(Server.URLEncode(ThisPageURL),TimeWindow,ForceLogin,CoBrandArgs,strLCID,Secure)%>
  179. </P>
  180. <% End If %>
  181. </BODY>
  182. <!-- #INCLUDE VIRTUAL = "include/asp/foot.asp" -->
  183. <%
  184. Call CDestroyObjects
  185. %>