Microsoft KB Archive/151347

From BetaArchive Wiki

FP1: How to Add JavaScript to a Page

Article ID: Q151347

The information in this article applies to:

  • Microsoft FrontPage for Windows, versions 1.0, 1.0a, 1.1

SUMMARY

The "More Information" section of this article includes the steps you need to follow to use JavaScript with FrontPage Editor.

Note that FrontPage 98 and 97 include a tool specifically designed for inserting Internet scripting languages in FrontPage pages.

NOTE: You must use a Java-enabled Web browser to view a page that includes JavaScript.

MORE INFORMATION

Java-enabled pages have fast become a method of making Web pages interactive. Because JavaScript relies on the browser to perform interactive functions, it is more reliable than CGI or PERL which are platform dependent.

Use the following steps to create a page that contains a form with a three- button text box:

1. In FrontPage Editor, create a new page in an existing Web.

2. On the Insert menu, click Bot, select the HTML Markup WebBot, and click

   OK.

3. In the WebBot HTML Markup dialog box, type the following:

   <SCRIPT LANGUAGE="LiveScript">
   <!-- This comment hides the script from old browsers
   function ShowText(form, strText)
   {
     form.display.value = strText;
   }
   -->
   </SCRIPT>

   <FORM>
   <INPUT TYPE="text" NAME="display" VALUE=""><BR>
   <INPUT TYPE="BUTTON" VALUE="One" ONCLICK="ShowText(this.form, 'One')">
   <INPUT TYPE="BUTTON" VALUE="Two" ONCLICK="ShowText(this.form, 'Two')">
   <INPUT TYPE="RESET" VALUE="Clear">
   </FORM>

4. Click OK to exit the WebBot HTML Markup dialog box.

   NOTE: You must place the form in the WebBot HTML Markup dialog box
   because the buttons have extended functionality.

5. Save the page to the Web and view it with a Java-enabled Web browser.

Additional query words: 1.00 1.x applet java script front page

Keywords          : kbusage kbdta
Version           : windows:1.0,1.0a,1.1
Platform          : WINDOWS
Hardware          : x86
Issue type        : kbhowto

Last Reviewed: September 30, 1998
© 1999 Microsoft Corporation. All rights reserved. Terms of Use.