Microsoft KB Archive/295606

= FP: How to Insert Script Code in a Shared Border of a Web =

Article ID: 295606

Article Last Modified on 1/31/2007

-

APPLIES TO


 * Microsoft FrontPage 2002 Standard Edition
 * Microsoft FrontPage 2000 Standard Edition

-



This article was previously published under Q295606



SUMMARY
This article describes how to insert script code into a shared border of a Web.



MORE INFORMATION
Microsoft provides programming examples for illustration only, without warranty either expressed or implied. This includes, but is not limited to, the implied warranties of merchantability or fitness for a particular purpose. This article assumes that you are familiar with the programming language that is being demonstrated and with the tools that are used to create and to debug procedures. Microsoft support engineers can help explain the functionality of a particular procedure, but they will not modify these examples to provide added functionality or construct procedures to meet your specific requirements. NOTE: You may receive an error message if you copy the examples directly from this article and paste them into FrontPage. The angle brackets may appear as escaped HTML code. To work around this behavior, paste the script into a blank Notepad document, and then copy it from Notepad before you paste it into FrontPage.

To add script code to a shared border, follow these steps:  Start FrontPage and open the Web site. To do this, click Open Web on the File menu, select the Web you want to open, and click Open. On the Tools menu, click Web Settings. Click the Advanced Settings tab. Click to select the Show hidden files and folders check box and click Apply.

NOTE: Shared borders are kept in a hidden folder named _borders. If you receive the following message

The changes you made in the Advanced Settings tab will take effect after the Web is refreshed from the server.

Do you want to refresh the Web now?

click Yes. Click OK to close the Web Settings dialog box. Double-click the _borders folder.

NOTE: You should see one or more of the following shared border pages:

 Top.htm (Top Shared Border)</li> Left.htm (Left Shared Border)</li> Right.htm (Right Shared Border)</li> Bottom.htm (Bottom Shared Border)</li></ul>

When you edit these files the information that appears in the borders is updated.</li> Right-click the file you want to modify and click Open on the menu that appears. For example, open the Top.htm page.</li> When the page opens in FrontPage, switch to HTML view.</li> Locate the opening <BODY> tag in the HTML code and click just after the tag. Press ENTER twice to create new lines.

WARNING: Information you type between the <BODY> and </BODY> tags in a shared border file appears in the border. Any code that you type in the <HEAD></HEAD> section is ignored. Therefore, to have the script be processed, place it in the document body section.</li>  On the new line, type the script code you want. For example, type the following script code: <script language=&quot;JavaScript&quot;>

</li> On the File menu, click Save to save the changes you made to the page.</li> On the File menu, click Close.</li></ol>

When you view your Web site in a Web browser, a message box similar to the following appears for each page that has the shared border:

This is in the TOP border.

<div class="references_section">