home *** CD-ROM | disk | FTP | other *** search
/ Di Gi Charat Mail / disc2.iso / disc2 / ie5 / IE_S2.CAB / IE_2.CAB / SHDOCLC.DLL / HTML / ANALYZE.DLG < prev    next >
Text File  |  1999-04-01  |  9KB  |  237 lines

  1. <HTML id=dlgAnalyze STYLE="font-family: MS UI Gothic; font-size: 9pt;
  2. width: 30em; height: 33em">
  3. <HEAD>
  4. <meta http-equiv="Content-Type" content="text/html; charset=shift_jis">
  5. <TITLE id=dialogTitle>
  6. âhâLâàâüâôâgé╠ò¬É═
  7. </TITLE>
  8. <SCRIPT LANGUAGE="JavaScript" defer>
  9. window.onerror = HandleError
  10. function HandleError(message, url, line)
  11. {
  12. var L_Dialog_ErrorMessage = "é▒é╠â_âCâAâìâOé┼âGâëü[é¬ö¡É╢é╡é▄é╡é╜üB";
  13. var L_ErrorNumber_Text = "âGâëü[: ";
  14. var str = L_Dialog_ErrorMessage + "\n\n" 
  15.  + L_ErrorNumber_Text + line + "\n"
  16.  + message;
  17. alert (str);
  18. window.close();
  19. return true;
  20. }
  21. function otherDocument() 
  22. {
  23. return window.dialogArguments.document;
  24. }
  25. function loadBdy()
  26. {
  27. document.all.btnOk.onclick = new Function("window.close();");
  28. document.onkeyup = new Function("documentOnKeyUp()");
  29. runAnalysis();
  30. function documentOnKeyUp()
  31. {
  32. if (window.event.keyCode == 27)
  33. {
  34.  window.close();
  35. }
  36. function runAnalysis() 
  37. var errorsFound, reportLocation;
  38. errorsFound = false;
  39. reportLocation = document.all.ReportArea;
  40. initializeResults(reportLocation);
  41. errorsFound = errorsFound || checkBodyWithinFrameset(reportLocation);
  42. errorsFound = errorsFound || checkAnythingAfterFrameset(reportLocation);
  43. errorsFound = errorsFound || checkUnloadedComponents(reportLocation);
  44. errorsFound = errorsFound || checkNonApartmentControls(reportLocation);
  45. errorsFound = errorsFound || checkUnloadedStyleSheets(reportLocation);
  46. if (errorsFound == false) {
  47.  reportNothingFound(reportLocation);
  48. }
  49. }
  50. function initializeResults(reportLocation) 
  51. {
  52. reportLocation.innerHTML = " ";
  53. }
  54. function reportNothingFound(reportLocation) 
  55. {
  56. var L_NoErrors_Text = "âGâëü[é═î⌐é┬é⌐éΦé▄é╣é±é┼é╡é╜üB";
  57. reportLocation.innerHTML = L_NoErrors_Text;
  58. }
  59. function checkBodyWithinFrameset(reportLocation) 
  60. {
  61. var theDocument;
  62. var framesets, bodies;
  63. var retVal;
  64. var L_FramesetInBody_Text = "âhâLâàâüâôâgé╠ BODY ôαé╔ FRAMESET é¬éáéΘé╜é▀üAé▒é╠âhâLâàâüâôâgé═É│é╡é¡ò\Īé│éΩé╚éóë┬ö\ɽé¬éáéΦé▄é╖üBâyü[âWé╠ì∞ɼÄ╥é═ăé╠ò√û@é┼é▒é╠ûΓæΦé≡ë≡îêé┼é½é▄é╖üB<OL><li>BODY â^âOé≡ìφÅ£é╖éΘüB</li><li>âhâLâàâüâôâgé╠ HEAD é╞ FRAMESET é╠è╘é╔ HTML âRü[âhé¬é╚éóé▒é╞é≡èmöFé╖éΘüB</li></ol><br><hr>";
  65. retVal = false;
  66. theDocument = otherDocument();
  67. framesets = theDocument.all.tags("frameset");
  68. if (framesets.length > 0) {
  69.  bodies = theDocument.all.tags("body");
  70.  if (bodies.length > 0) {
  71.   reportLocation.insertAdjacentHTML("BeforeEnd", L_FramesetInBody_Text );
  72.   retVal = true;
  73.  }
  74. }
  75. return retVal;
  76. }
  77. function checkAnythingAfterFrameset(reportLocation) 
  78. {
  79. var L_ContentAfterFrameset_Text = "FRAMESET é╠îπé╔âRâôâeâôâcé¬éáéΘé╜é▀üAé▒é╠âhâLâàâüâôâgé═É│é╡é¡ò\Īé│éΩé╚éóë┬ö\ɽé¬éáéΦé▄é╖üB<br><hr>";
  80. var theDocument;
  81. var framesets;
  82. var i, startIndex;
  83. var retVal;
  84. retVal = false;
  85. theDocument = otherDocument();
  86. framesets = theDocument.all.tags("frameset");
  87. if (framesets.length > 0) {
  88.  startIndex = framesets(0).sourceIndex;
  89.  if (window.dialogArguments.anythingAfterFrameset) {
  90.  reportLocation.insertAdjacentHTML("BeforeEnd", L_ContentAfterFrameset_Text );
  91.  retVal = true;
  92.  }
  93. }
  94. return retVal;
  95. }
  96. function checkUnloadedComponents(reportLocation) 
  97. {
  98. var theDocument;
  99. var objects, applets, embeds;
  100. var retVal;
  101. retVal = false;
  102. theDocument = otherDocument();
  103. objects = theDocument.all.tags("object");
  104. applets = theDocument.all.tags("applet");
  105. embeds = theDocument.all.tags("embed");
  106. retVal = checkReadyStateComplete(objects, reportLocation);
  107. retVal = retVal || checkReadyStateComplete(applets, reportLocation);
  108. retVal = retVal || checkReadyStateComplete(embeds, reportLocation);
  109. return retVal;
  110. }
  111. function checkReadyStateComplete(objects, reportLocation) 
  112. {
  113. var L_ObjectNotInstalled_Text = "ăé╠ OBJECT é═É│Åφé╔âCâôâXâgü[âïé│éΩé▄é╣é±é┼é╡é╜üB<BR>";
  114. var L_AppletNotInstalled_Text = "ăé╠ APPLET é═É│Åφé╔âCâôâXâgü[âïé│éΩé▄é╣é±é┼é╡é╜üB<BR>";
  115. var L_EmbedNotInstalled_Text = "ăé╠ EMBED é═É│Åφé╔âCâôâXâgü[âïé│éΩé▄é╣é±é┼é╡é╜üB<BR>";
  116. var L_ObjectNotInstalledReasons_Text = "<br><br>ê╚ë║é╔ìléªéτéΩéΘî┤ê÷é≡Åqé╫é─éóé▄é╖:<OL><LI>î╗ì▌é╠âZâLâàâèâeâBé╠É▌ÆΦé┼é═üAé▒é╠ OBJECT é═Ägùpé┼é½é╚éóüB</li><li>é▒é╠ OBJECT é═âRâôâsâàü[â^é╔É│Åφé╔âCâôâXâgü[âïé│éΩé─éóé╚éóüB</li><li>âyü[âWé▄é╜é═ OBJECT é¬è╘êßé┴é─ì∞ɼé│éΩé─éóéΘüB</li></ul><hr>";
  117. var L_AppletNotInstalledReasons_Text = "<br><br>ê╚ë║é╔ìléªéτéΩéΘî┤ê÷é≡Åqé╫é─éóé▄é╖:<OL><LI>î╗ì▌é╠âZâLâàâèâeâBé╠É▌ÆΦé┼é═üAé▒é╠ APPLET é═Ägùpé┼é½é╚éóüB</li><li>é▒é╠ APPLET é═âRâôâsâàü[â^é╔É│Åφé╔âCâôâXâgü[âïé│éΩé─éóé╚éóüB</li><li>âyü[âWé▄é╜é═ APPLET é¬è╘êßé┴é─ì∞ɼé│éΩé─éóéΘüB</li></ul><hr>";
  118. var L_EmbedNotInstalledReasons_Text = "<br><br>ê╚ë║é╔ìléªéτéΩéΘî┤ê÷é≡Åqé╫é─éóé▄é╖:<OL><LI>î╗ì▌é╠âZâLâàâèâeâBé╠É▌ÆΦé┼é═üAé▒é╠ EMBED é═Ägùpé┼é½é╚éóüB</li><li>é▒é╠ EMBED é═âRâôâsâàü[â^é╔É│Åφé╔âCâôâXâgü[âïé│éΩé─éóé╚éóüB</li><li>âyü[âWé▄é╜é═ EMBED é¬è╘êßé┴é─ì∞ɼé│éΩé─éóéΘüB</li></ul><hr>";
  119. var strNotInstalled;
  120. var strNotInstalledReason;
  121. var i, element;
  122. var retVal;
  123. retVal = false;
  124. if (objects == null) 
  125.  return retVal;
  126. for (i=0; i < objects.length; i++) {
  127.  element = objects(i);
  128.  if (element.readyState != 4 && element.readyState != "complete") {
  129.   switch (element.tagName.toLowerCase())
  130.   {
  131.   case "object":
  132.    strNotInstalled = L_ObjectNotInstalled_Text;
  133.    strNotInstalledReason = L_ObjectNotInstalledReasons_Text;
  134.    break;
  135.   case "applet":
  136.    strNotInstalled = L_AppletNotInstalled_Text;
  137.    strNotInstalledReason = L_AppletNotInstalledReasons_Text;
  138.    break;
  139.   case "embed":
  140.    strNotInstalled = L_EmbedNotInstalled_Text;
  141.    strNotInstalledReason = L_EmbedNotInstalledReasons_Text;
  142.    break;
  143.   }
  144.  reportLocation.insertAdjacentHTML("BeforeEnd", strNotInstalled);
  145.  reportLocation.insertAdjacentText("BeforeEnd", element.outerHTML);
  146.  reportLocation.insertAdjacentHTML("BeforeEnd", strNotInstalledReason);
  147.  retVal = true;
  148.  }
  149. }
  150. return retVal;
  151. }
  152. function checkNonApartmentControls(reportLocation) 
  153. {
  154. var L_ObjectNotApartmentModel_Text = "ăé╠ OBJECT é═âAâpü[âgâüâôâg âXâîâbâh âéâfâïé≡Ägùpé╡é─éóé╚éóé╜é▀üAêΩòöé╠è┬ï½é┼É│é╡é¡ï@ö\é╡é╚éóë┬ö\ɽé¬éáéΦé▄é╖üB<br>";
  155. var theDocument;
  156. var objects;
  157. var i;
  158. var retVal;
  159. retVal = false;
  160. theDocument = otherDocument();
  161. objects = theDocument.all.tags("object");
  162. for (i=0; i < objects.length; i++) {
  163.  element = objects(i);
  164.  nonApartmentModel = checkCLSIDForNonApartmentModel(element);
  165.  retVal = retVal || nonApartmentModel;
  166.  if (nonApartmentModel == true) {
  167.  reportLocation.insertAdjacentHTML("BeforeEnd", L_ObjectNotApartmentModel_Text);
  168.  reportLocation.insertAdjacentText("BeforeEnd", element.outerHTML);
  169.  reportLocation.insertAdjacentHTML("BeforeEnd", "<br><hr>");
  170.  }
  171. return retVal;
  172. }
  173. function checkCLSIDForNonApartmentModel(element) {
  174. return !(window.dialogArguments.isApartmentModel(element));
  175. }
  176. function checkUnloadedStyleSheets(reportLocation) 
  177. {
  178. var theDocument;
  179. var links;
  180. var retVal;
  181. retVal = false;
  182. theDocument = otherDocument();
  183. links = theDocument.all.tags("link");
  184. retVal = checkLinkReadyStateComplete(links, reportLocation);
  185. return retVal;
  186. }
  187. function checkLinkReadyStateComplete(objects, reportLocation) 
  188. {
  189. var i, element;
  190. var retVal;
  191. var L_StyleSheetNotInstalled_Text = "ăé╠âXâ^âCâï âVü[âgé═âCâôâXâgü[âïé│éΩé─éóé╚éóé╜é▀üAé▒é╠âhâLâàâüâôâgé═É│Åφé╔ò\Īé│éΩé╚éóë┬ö\ɽé¬éáéΦé▄é╖ : ";
  192. retVal = false;
  193. if (objects == null) 
  194.  return retVal;
  195. for (i=0; i < objects.length; i++) {
  196.  element = objects(i);
  197.  if (element.rel.toLowerCase() == "stylesheet"
  198.   || element.rel.toLowerCase() == "alternate stylesheet")
  199.  {
  200.   if (element.readyState != "complete" && element.readyState != 4) {
  201.   reportLocation.insertAdjacentHTML("BeforeEnd", L_StyleSheetNotInstalled_Text + element.href + "<BR><hr>");
  202.   retVal = true;
  203.   }
  204.  }
  205.  }
  206. return retVal;
  207. }
  208. </SCRIPT>
  209. </HEAD>
  210. <BODY ID=bdy onLoad="loadBdy()" style="font-family: 'MS UI Gothic';
  211. font-size: 9pt; background: threedface; color: windowtext;" 
  212. topmargin=0 scroll=no>
  213. <br id=brAnalysis>  î╗ì▌é╠âhâLâàâüâôâgé╠ò¬É═:<br>
  214. <br>
  215. <DIV id=ReportArea style="height: 75%; width: 93%; 
  216. position: absolute; left: 5%; top: 12%; overflow: auto; padding: 3px;
  217. border-style: solid; border-width: 1px; border-color: threeddarkshadow">
  218. âGâëü[é═î⌐é┬é⌐éΦé▄é╣é±é┼é╡é╜üB
  219. </DIV>
  220. <br id=br2><P id=par1