Dennis' Domino Blog
« IBM DB2 prior to 9.7 Fix Pack 2 Multiple Security VulnerabilitiesInterfaceFLOR news: 'War on waste' and EPD »

xpages: Theme's and css media types

  05/31/10 10:52, by dennisvr, Categories: Lotus, xpages

This weekend I was trying to embed blueprint in a xpages app.
All went fine, but I ran into 1 problem: How do you get your theme to use the following syntax?

<!--sample -->
<!-- Framework CSS -->
<link rel="stylesheet" href="../../blueprint/screen.css" type="text/css" media="screen, projection">
<link rel="stylesheet" href="../../blueprint/print.css" type="text/css" media="print">
<!--[if lt IE 8]>
<!-- Import fancy-type plugin for the sample page. -->
<link rel="stylesheet" href="../../blueprint/plugins/fancy-type/screen.css" type="text/css" media="screen, projection">

The media= part I can't fix with the theme? I tried the following:

<media>screen, projection</media>

But the generated code doesn't take the media stuff into account at all.

<link rel="stylesheet" type="text/css" href="/dev/blueprint.nsf/screen.css">
<link rel="stylesheet" type="text/css" href="/dev/blueprint.nsf/fancyscreen.css">

Any suggestions on this?


User ratings
5 star:
4 star:
3 star:
2 star:
1 star:
1 rating
Average user rating:
2.0 stars
The media attribute is not currently supported under XPages. It is something that has been requested, and I believe is being looked at.
05/31/10 @ 13:13
Comment from: dennisvr  
Thanks Jeremy!
05/31/10 @ 13:25
An alternative syntax resources is implemented in R8.5.2 (beta) and it supports the media attribute....The syntax is something like this: <resources> <styleSheet media="print" type="text/css" href="/path/to/stylesheet.css"></styleSheet> </resources> I don't know if the syntax will change or if it even makes it to the final build (as always with beta software) but we can at least hope(the syntax is much cleaner imho).
06/01/10 @ 12:00
Comment from: dennisvr  
Thanks Frederik Let's hope this makes the gold release then ;-)
06/01/10 @ 13:09
Comment from: mark b
2 stars
Browsers will respect media commands embedded in a style sheet with XPages before 8.5.2, for example: @media print { .buttonLeft {display:none} .buttonRight {display:none} .locallinks {display:none} } @media screen { .buttonLeft {display:block} .buttonRight {display:block} .locallinks {display:block} }
07/08/10 @ 17:04
Comment from: dennisvr  
Thanks Mark Excellent tip!!
07/08/10 @ 17:13
Yet another Domino/Websphere Admin blog.

About me:
Lotus Notes/Domino Admin
Websphere Commerce Admin


  XML Feeds

Planet Lotus

powered by b2evolution free blog software

©2017 by Dennis van Remortel

Contact | Help | b2evolution skin by Asevo | blog software | hosting