JavaScript DHTML/Language Basics/Code Layout
Версия от 09:59, 26 мая 2010; (обсуждение)
Содержание
A Script in the Body
<html>
<HEAD>
<TITLE>A Document</TITLE>
</HEAD>
<BODY>
<SCRIPT LANGUAGE="JavaScript">
//script statement(s) here
...
</SCRIPT>
</BODY>
</HTML>
Hiding Scripts from Most Old Browsers
<SCRIPT LANGUAGE="JavaScript">
<!--
//script statement(s) here
...
// -->
</SCRIPT>
Scripts in the Head
<html>
<HEAD>
<TITLE>A Document</TITLE>
<SCRIPT LANGUAGE="JavaScript">
//script statement(s) here
...
</SCRIPT>
</HEAD>
<BODY>
</BODY>
</HTML>
Scripts in the Head and Body
<HTML>
<HEAD>
<TITLE>A Document</TITLE>
<SCRIPT LANGUAGE="JavaScript">
//script statement(s) here
...
</SCRIPT>
</HEAD>
<BODY>
<SCRIPT LANGUAGE="JavaScript">
//script statement(s) here
...
</SCRIPT>
</BODY>
</HTML>
Two Scripts in the Body
<HTML>
<HEAD>
<TITLE>A Document</TITLE>
</HEAD>
<BODY>
<SCRIPT LANGUAGE="JavaScript">
//script statement(s) here
...
</SCRIPT>
<MORE HTML>
<SCRIPT LANGUAGE="JavaScript">
//script statement(s) here
...
</SCRIPT>
</BODY>
</HTML>