Using Adobe GoLive CS, Part 3 - External CSS
(Page 12 of 15 )
Although internal style sheets are useful, it's the external version that has the real power. When you reference an external style sheet from multiple pages in a site, all it takes is an edit to that one CSS document to make a quick site-wide change.
You can create a new external style sheet by choosing New Special, Cascading Style Sheet from the File menu, or by (Control-clicking) [right-clicking] in the site window and choosing New, Cascading Style Sheet. After the CSS Editor for your external style sheet opens, create your definitions in exactly the same manner as you did for internal styles. When you are finished, save and name the file, but be sure to keep the .css extension.
At times you might want to define an internal style sheet for a page and also link to an external style sheet. You can do this several ways. From an internal CSS Editor window, click Create a Reference to an External Style Sheet, and in the next window use the Fetch URL tool to link to the CSS document in your site window (see Figure 9.86).
Another method is to drag a CSS file from the Files tab of the site window and drop it onto the Page Properties button at the upper right of the page (see Figure 9.87).

Figure 9.86 You can link directly from the page's
internal CSS Editor to an external CSS file.

Figure 9.87 Drag and drop a CSS file onto the
Page Properties button to create a link.
A third way is to use the CSS palette. First select the page or pages in the Files list of the site window, and then click and hold the mouse on the Create Link to External CSS button and choose the name of the CSS file to which you want to link (see Figure 9.88). Alternatively, you could select the pages in the Files list and use the Fetch URL tool or browser button in the CSS palette.

Figure 9.88 Use the CSS palette to link multiple
pages to an external CSS file.
There are entire books devoted to CSS, but hopefully this section will get you started. CSS is somewhat addicting. After you realize its incredible power, you'll never want to go back to the old way of styling your pages again!
JavaScript Actions
JavaScript is a language especially for browsers that allows for interactivity beyond the scope of plain HTML. GoLive CS comes with a whole bunch of prewritten JavaScripts called Actions. Using the Rollovers and Actions palette, you can set up an Action to perform a whole range of tasks and never write one word of JavaScript.
Actions must be triggered somehow, either by a move the visitor makes, such as clicking a link or submitting a form, or by something the browser does, such as loading a page. Although there isn't space in this book to show how to use each and every GoLive Action, we will look at the basics of how to set them up.
Open the Rollovers & Actions palette from the Window menu, and then click the Actions button. We'll create a very simple action to get your started. Follow these steps:
From the File menu choose New Page.
Type Please choose a size on the page.
Select the text, and in the Inspector palette type a pound sign ( #) into the URL field to create a dummy link.
In the Actions palette, click Mouse Click.
Click the Create New Action button.
From the Actions pop-up list choose Link, Open Window Prompt.
That's it! Now, preview the page in a browser and click the link. You'll be asked to enter a width and then a height, and then the page will reload itself into a browser window at the size you just requested.
That is one small example of what you can do, but there are many more tricks easily accomplished with GoLive Actions. For specific instructions on setting up a particular Action, check GoLive's help files, accessible from the Help menu. Remember, too, that the Actions that ship with GoLive are only a few of the many available. A quick search on Google for GoLive Actions should turn up a list of both free and commercial varieties.
This chapter is from Teach Yourself Adobe Creative Suite, by Mordy Golding (Sams, 2004, ISBN: 067232752X). Check it out at your favorite bookstore today.
Buy this book now. |
Next: Link Warnings >>
More Web Authoring Articles
More By Sams Publishing