Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
HTML column and CSS
ultraslug
Hello! I have a report which displays a database column containing basic HTML. What sort of CSS styling can be done with this? I tried creating a computed column that injects CSS tags before the data, but that doesn't seem to work.
I see the Text block item supports HTML, but I can't find any information about how (or if) the tags listed in the dialog box can be styled. When you choose Layout from the dropdown it shows DIV, which isn't very useful without a way to style it so I'm thinking there has to be a way.
(Edit: using Eclipse BIRT Designer Version 2.6.1)
Find more posts tagged with
Comments
johnw
<blockquote class='ipsBlockquote' data-author="'ultraslug'" data-cid="69926" data-time="1288681628" data-date="02 November 2010 - 12:07 AM"><p>
Hello! I have a report which displays a database column containing basic HTML. What sort of CSS styling can be done with this? I tried creating a computed column that injects CSS tags before the data, but that doesn't seem to work.<br />
<br />
I see the Text block item supports HTML, but I can't find any information about how (or if) the tags listed in the dialog box can be styled. When you choose Layout from the dropdown it shows DIV, which isn't very useful without a way to style it so I'm thinking there has to be a way.<br />
<br />
(Edit: using Eclipse BIRT Designer Version 2.6.1)<br /></p></blockquote>
<br />
You have two options, BIRT CSS styles, or client side CSS styles. If you want to use client side CSS, you will ned a TEXT element, set to HTML, with a include statement with the CSS definitions, or you will need to modify in some way (probably by calling a reportlet instead of a report), and add in your own HEAD statement with CSS definitions. You could also set the BOOKMARK property of a report item, which will set the ID tag of a surrounding DIV to that value.<br />
<br />
BIRT CSS is applied server side, and will basically tell the render engine to set the style property of generated elements at run time. <br />
<br />
Its going to be up to you which method you prefer. The BIRT css is usually enough, and you can define your styles in an external text and include it. Just keep in mind this is applied at run time, this does not tell BIRT to include the CSS file in the same manner that HTML CSS works.<br />
<br />
john
krahe
Exactly what is "a include statement with the CSS definitions"?<br />
<br />
I have several Text items that show HTML documents stored in my database. While that HTML often includes tags like <H1> and <body>, I have not found a way to control the style of those elements in the final report. For instance, I would like to be able to define a style for <H1> in one place for all of the Text elements in the report that render HTML. I have tried including <pre class='_prettyXprint _lang-auto _linenums:0'><link rel = "stylesheet" type = "text/css" href = "myStyle.css" /></pre> in the <head> section of the HTML documents stored in the database, but they have no effect.<br />
<br />
I'm using BIRT 2.6.1.