Macromedia dreamweaver 8-extending dreamweaver 사용자 설명서

다운로드
페이지 504
A simple command example
169
This example creates two files in the Commands folder: Change Case.htm, which contains 
the UI, and Change Case.js, which contains the JavaScript code. If you prefer, you can create 
only the Change Case.htm file and put the JavaScript code in the 
HEAD
 section.
Creating the UI
The UI is a form that contains two radio buttons that let the user select uppercase or 
lowercase. 
To create the user interface:
1.
Create a new blank file.
2.
Add the following code to the file to create the form:
<!DOCTYPE HTML SYSTEM "-//Macromedia//DWExtension layout-engine 5.0//
dialog">
<HTML>
<HEAD>
<!-- Copyright 2001-2002 Macromedia, Inc. All rights reserved. -->
<Title>Make Uppercase or Lowercase</Title>
<SCRIPT SRC="Change Selection Case.js"></SCRIPT>
</HEAD>
<BODY>
 <form name="uorl">
  <table border="0">
    <!--DWLayoutTable-->
    <tr> 
      <td valign="top" nowrap> <p> 
          <label> 
          <input type="radio" name="RadioGroup1" value="uppercase" 
checked>
          Uppercase</label>
          <br>
          <label> 
          <input type="radio" name="RadioGroup1" value="lowercase">
          Lowercase</label>
        </p></td>
    </tr>
  </table>
  </div>
</form>
</BODY>
</HTML>
3.
Save the file as Change Case.htm in the Configuration/Commands folder.