Home
Analytics
BIRT_ROOT div tag ID - how to change it
Mattwm
<p>I have developed a number of reports that are to be displayed on a JSP using JQuery for a tabbed page for multiple reports. When I pull one report into the page, everything works fine because there is just one report with a tag ID of "__BIRT_ROOT". However, when I open 2 or more reports, it corrupts them all because there is now multiple div tags on the page with an ID of "__BIRT_ROOT". Is there a way to change this root div ID?</p>
<p> </p>
<p> </p>
Find more posts tagged with
Comments
Mattwm
<p>Although I still believe that having 2 div tag IDs with the same name is bad practice, and BIRT should fix this, the IDs were not the issue. When pulling in multiple reports onto a page, each report brings it's own styles with it, and they are named the same. For example, style_0, style_1, style_2...etc. The styles were conflicting with each other. In our service code, this is in the Spring Framework, we have a BIRT class called HTMLRenderOption, and within this class is a setting called setHTMLIDNamespace(). We used our report name to set this option, ie setHTMLIDNamespace(reportNameSpace). This allowed each style to be prefixed with the name of the report, making it unique. I hope this helps someone who might see this in the future.</p>