Quick Tip: Adding New Selectors to GoLive's Default List

Default Element Selectors List

GoLive has a number of HTML selectors already available when you choose New Style from the CSS Editor flyout menu or context clicking on the CSS editor window. These are not set in stone. You can add selectors you habitually style to the list and remove any elements which you do not normally use if you want. Here's how.


Step 1:
Open the selectors.pref file from the Settings/MarkupBasics folder * underneath the GoLive install folder in a plain text editor such as Notepad or BBEdit Lite. You can open it GoLive and edit it there (as I am doing here), but you will need to create a new entry for the pref extension in the File Mappings section of the Web Settings. Want to know how to do that? GoLive in 24 has a tip on doing exactly that. NB.The mime type for selectors.pref is text/xml, so in this case copy the XML entry rather than the HTML entry as in the tip.


* In GoLive 5.0, the file is cssselectors.cdtd and it is in the Modules/Web Settings/Browser/Settings folder under the GoLive install folder.

Open the CSS Editor

Step 2:
Add new entries to the selectors.pref file for the selectors you would like to have available in the New Style list. Here we have added entries for the first three heading elements, h1 through h3.


Create a Rule

Step 3:
Save the file. Restart GoLive. The new selectors you defined in selectors.pref (or cssselectors.cdtd) will be available in the New Style flyout (or the CSS editor contextual menu.


Select CSS Icon in Head Section

More Info:
You are not limited to HTML element selectors, by the way. If there are ID or class styles which you always use, site to site, it might be worth putting them in here. For example, if you usually divide your pages in to ID'ed divs for header, content and footer, you might want those available in the flyout.


Duplicate the Stylesheet



More Info:
Here we've set up a couple of classes for something we might frequently want to create.



A nice little tip, I think, for customising the GoLive interface and make it and your workflow fit better. And life easier.