Two methods for referencing CSS files in Domino

Interested in using the same stylesheet throughout your Web site? Want to see how? Here are two easy ways!

Interested in using the same stylesheet throughout your Web site? Want to see how? Here are two easy ways! PART

ONE: PLACEMENT OF THE CSS FILE

OPTION 1) Using a page or form
-Paste your CSS code into a form/page.
-Select the "Treat contects as HTML" form/page property.
-Do not include the style tags.
-Comment your code like you would HTML. (ie. <!-- ##### DHTML Business Menu Anchors ##### --> )

OPTION 2: Using Image Resource
-Create a new Image Resource, Select your CSS file.
-Name it manually including the extension. (i.e. stylesheet.css)

INCLUDING THE FILE

-Paste the following code into the HTML Head Content object on a page/form: (Or, for 4.6 users, into the $$HTMLHead field.)

"<LINK REL=stylesheet TYPE="text/css" HREF="aliasOfStylesheet?OpenPage">"

Above, the stylesheet was created on a page. If you used a form, it would be ?OpenForm. Likewise, ?OpenImageResource for an Image Resource using the whole filename.

Which is better?
If your good at modifying CSS on the fly, it may be useful to use a form/page to quickly modify the style. Otherwise, use a CSS editor and delete/reattach the new file when you edit it. Image Resource is best used if multiple sites refernce the same stylesheet.

Note: a third way would be pasting your CSS code into a subform, and including it on a form. Cons: 1) You have to use a form. 2) I've experienced inconsistencies with how the browser reads and caches the file.

This was first published in January 2001

Dig deeper on Domino Resources - Part 4

1 comment

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

SearchWinIT

Search400

  • iSeries tutorials

    Search400.com's tutorials provide in-depth information on the iSeries. Our iSeries tutorials address areas you need to know about...

  • V6R1 upgrade planning checklist

    When upgrading to V6R1, make sure your software will be supported, your programs will function and the correct PTFs have been ...

  • Connecting multiple iSeries systems through DDM

    Working with databases over multiple iSeries systems can be simple when remotely connecting logical partitions with distributed ...

SearchEnterpriseLinux

SearchVirtualDataCentre.co.uk

Close