⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dom_obj_document.asp@output=print

📁 W3Schools tutorial..web designing
💻 ASP@OUTPUT=PRINT
字号:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en-US" xml:lang="en-US" xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>HTML DOM Document Object</title>
 
<link rel="shortcut icon" href="../favicon.ico" type="image/x-icon" />
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<meta name="Keywords" content="xml,tutorial,html,dhtml,css,xsl,xhtml,javascript,asp,ado,vbscript,dom,sql,colors,soap,php,authoring,programming,training,learning,beginner's guide,primer,lessons,school,howto,reference,examples,samples,source code,tags,demos,tips,links,FAQ,tag list,forms,frames,color table,w3c,cascading style sheets,active server pages,dynamic html,internet,database,development,Web building,Webmaster,html guide" />

<meta name="Description" content="Free HTML XHTML CSS JavaScript DHTML XML DOM XSL XSLT RSS AJAX ASP ADO PHP SQL tutorials, references, examples for web building." />

<meta http-equiv="pragma" content="no-cache" />
<meta http-equiv="cache-control" content="no-cache" />

<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "../../https@ssl./default.htm" : "../../www./default.htm");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
var pageTracker = _gat._getTracker("UA-3855518-1");
pageTracker._initData();
pageTracker._trackPageview();
</script>

</head>
<body>

<p>From <b>http://www.w3schools.com</b> (Copyright Refsnes Data)</p>

<h1>HTML DOM Document Object</h1>
<hr />

<h2>Document Object</h2>

<p>The Document object represents the entire HTML document and can be used to access all elements in a page.</p>
<p>The Document object is part of the Window object and is accessed through the 
window.document property.</p>

<p>
<b>IE:</b> Internet Explorer, <b>F:</b> Firefox, <b>O:</b> Opera, <b>W3C:</b> 
World Wide Web Consortium (Internet Standard).</p>

<h3>Document Object Collections</h3>
<table class="ex" cellspacing="0" border="1" width="100%">
  <tr>
    <th width="30%" align="left">Collection</th>
    <th width="50%" align="left">Description</th>
    <th width="5%" align="left">IE</th>
    <th width="4%" align="left">F</th>
    <th width="4%" align="left">O</th>
    <th width="7%" align="left">W3C</th>
  </tr>
  <tr>
    <td valign="top"><a href="coll_doc_anchors.asp">anchors[]</a></td>
    <td valign="top">Returns a reference to all Anchor objects in the document</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
  </tr>
  <tr>
    <td valign="top"><a href="coll_doc_forms.asp">forms[]</a></td>
    <td valign="top">Returns a reference to all Form objects in the document</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
  </tr>
  <tr>
    <td valign="top"><a href="coll_doc_images.asp">images[]</a></td>
    <td valign="top">Returns a reference to all Image objects in the document</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
  </tr>
  <tr>
    <td valign="top"><a href="coll_doc_links.asp">links[]</a></td>
    <td valign="top">Returns a reference to all Area and Link objects in the document</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
  </tr>
  </table>

<h3>Document Object Properties</h3>

<table class="ex" cellspacing="0" border="1" width="100%">
  <tr>
    <th width="30%" align="left">Property</th>
    <th width="50%" align="left">Description</th>
    <th width="5%" align="left">IE</th>
    <th width="4%" align="left">F</th>
    <th width="4%" align="left">O</th>
    <th width="7%" align="left">W3C</th>
  </tr>
  <tr>
    <td valign="top">body</td>
    <td valign="top">Gives direct access to the &lt;body&gt; element</td>
    <td valign="top">&nbsp;</td>
    <td valign="top">&nbsp;</td>
    <td valign="top">&nbsp;</td>
    <td valign="top">&nbsp;</td>
  </tr>
  <tr>
    <td valign="top"><a href="prop_doc_cookie.asp">cookie</a></td>
    <td valign="top">Sets or returns all cookies associated with the current document</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
  </tr>
  <tr>
    <td valign="top"><a href="prop_doc_domain.asp">domain</a></td>
    <td valign="top">Returns the domain name for the current document</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
  </tr>
  <tr>
    <td valign="top"><a href="prop_doc_lastmodified.asp">lastModified</a></td>
    <td valign="top">Returns the date and time a document was last modified</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">No</td>
    <td valign="top">No</td>
  </tr>
  <tr>
    <td valign="top"><a href="prop_doc_referrer.asp">referrer</a></td>
    <td valign="top">Returns the URL of the document that loaded the current 
    document</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
  </tr>
  <tr>
    <td valign="top"><a href="prop_doc_title.asp">title</a></td>
    <td valign="top">Returns the title of the current document</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
  </tr>
  <tr>
    <td valign="top"><a href="prop_doc_url.asp">URL</a></td>
    <td valign="top">Returns the URL of the current document</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
  </tr>
  </table>

<h3>Document Object Methods</h3>

<table class="ex" cellspacing="0" border="1" width="100%">
  <tr>
    <th width="32%" align="left" valign="top">Method</th>
    <th width="48%" align="left" valign="top">Description</th>
    <th width="5%" align="left" valign="top">IE</th>
    <th width="4%" align="left" valign="top">F</th>
    <th width="4%" align="left" valign="top">O</th>
    <th width="7%" align="left" valign="top">W3C</th>
  </tr>
  <tr>
    <td valign="top"><a href="met_doc_close.asp">close()</a></td>
    <td valign="top">Closes an output stream opened with the document.open() 
	method, and displays the collected data</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
    </tr>
  <tr>
    <td valign="top"><a href="met_doc_getelementbyid.asp">getElementById()</a></td>
    <td valign="top">Returns a reference to the first object with the specified 
    id</td>
    <td valign="top">5</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
    </tr>
  <tr>
    <td valign="top"><a href="met_doc_getelementsbyname.asp">getElementsByName()</a></td>
    <td valign="top">Returns a collection of objects with the specified name</td>
    <td valign="top">5</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
    </tr>
  <tr>
    <td valign="top"><a href="met_doc_getelementsbytagname.asp">getElementsByTagName()</a></td>
    <td valign="top">Returns a collection of objects with the specified tagname</td>
    <td valign="top">5</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
    </tr>
  <tr>
    <td valign="top"><a href="met_doc_open.asp">open()</a></td>
    <td valign="top">Opens a stream to collect the output from any document.write() or document.writeln() 
	methods</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
    </tr>
  <tr>
    <td valign="top"><a href="met_doc_write.asp">write()</a></td>
    <td valign="top">Writes HTML expressions or JavaScript code to a document</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
    </tr>
  <tr>
    <td valign="top"><a href="met_doc_writeln.asp">writeln()</a></td>
    <td valign="top">Identical to the write() method, with the addition of 
	writing a new line character after each expression</td>
    <td valign="top">4</td>
    <td valign="top">1</td>
    <td valign="top">9</td>
    <td valign="top">Yes</td>
    </tr>
  </table>
<br />
<hr />

<p>From <b>http://www.w3schools.com</b> (Copyright Refsnes Data)</p>

</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -