473,402 Members | 2,050 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,402 software developers and data experts.

Having problems on Mozilla firefox (not able to see xml data)..Pls Help.

i m trying to see the xml in a browser using an xslt....

My xml i have defined as

<?xml version=" 1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="Topic_publications_xsl.xsl"?>
<!DOCTYPE root [
<!ENTITY about SYSTEM "publications.xml">

]>

<root>
&about;
</root>


so its extending publications.xml which has the data...

and Topic_publications_xsl.xsl has the logic of showing the data on the browser..

Now this works great on IE but on mozilla firefox it has problems and does not show the data...

Do u have any idea on this??

Also there is a point on mozilla firefox that it does nt accept external DTD's. So is this the reason..

Thanks for the help.
Mar 13 '07 #1
4 1684
dorinbogdan
839 Expert 512MB
What error do you get?
Please post your XSL code, and XML working in IE.
Mar 13 '07 #2
drhowarddrfine
7,435 Expert 4TB
I haven't messed with xml in quite a while but, if this has to do with external entities, it is my understanding Firefox does not handle those yet.
Mar 13 '07 #3
What error do you get?
Please post your XSL code, and XML working in IE.
Ya sure. so there is

Topic_Publications_xml.xml which extends publications.xml

also Topic_Publications_xml.xml used Topic_Publications_xsl.xsl to display on web browser.

Expand|Select|Wrap|Line Numbers
  1.  for Topic_Publications_xml.xml
  2.  
  3.  
Expand|Select|Wrap|Line Numbers
  1. <?xml version="1.0" encoding="ISO-8859-1"?>
  2. <?xml-stylesheet type="text/xsl" href="Topic_publications_xsl.xsl"?>
  3. <!DOCTYPE root [
  4. <!ENTITY about SYSTEM "publications.xml">
  5. ]>
  6. <root>
  7.     &about;
  8. </root>
  9.  
  10.  
  11.  
  12.  



[b]
Expand|Select|Wrap|Line Numbers
  1.  for publications.xml
  2.  
  3.  
  4. <?xml version="1.0" encoding="ISO-8859-1"?>
  5.  
  6.  
  7.  
  8. <!-- Template that can be added. Plug in the values and it will be displayed.
  9.  
  10. <Paper monthid="some number">
  11. <Area> </Area>
  12. <Author>
  13. <Name>Ravi Sundaram</Name>
  14. </Author>
  15. <Topic></Topic>
  16. <Year></Year>
  17. <Month></Month>
  18. <Abstract-link></Abstract-link>
  19. <Full-Paper-link></Full-Paper-link>
  20. <Abstract></Abstract>
  21. <Conference></Conference>
  22. </Paper>
  23. -->
  24. <Publications>
  25.  
  26. <Paper > <!--paper 1-->
  27. <Area>A</Area>
  28. <!--<Author>
  29. <Name>Ravi Sundaram</Name>
  30. </Author>-->
  31. <Author>
  32. <Name>abcd</Name>
  33. </Author>
  34. <Author>
  35. <Name>acdsg</Name>
  36. </Author>
  37. <Author>
  38. <Name>bhah</Name>
  39. </Author>
  40. <Topic>hhkjj</Topic>
  41. <Year>2006</Year>
  42. <Month></Month>
  43. <Abstract-link></Abstract-link>
  44. <Full-Paper-link>ghh</Full-Paper-link>
  45. <Abstract>ggg</Abstract>
  46. <Conference>cncna</Conference>
  47. </Paper>
  48.  
  49. <Paper > <!--paper 1-->
  50. <Area>A</Area>
  51. <!--<Author>
  52. <Name>Ravi Sundaram</Name>
  53. </Author>-->
  54. <Author>
  55. <Name>abcd</Name>
  56. </Author>
  57. <Author>
  58. <Name>acdsg</Name>
  59. </Author>
  60. <Author>
  61. <Name>bhah</Name>
  62. </Author>
  63. <Topic>hhkjj</Topic>
  64. <Year>2006</Year>
  65. <Month></Month>
  66. <Abstract-link></Abstract-link>
  67. <Full-Paper-link>ghh</Full-Paper-link>
  68. <Abstract>ggg</Abstract>
  69. <Conference>cncna</Conference>
  70. </Paper>
  71.  
  72. <Paper > <!--paper 1-->
  73. <Area>A</Area>
  74. <!--<Author>
  75. <Name>Ravi Sundaram</Name>
  76. </Author>-->
  77. <Author>
  78. <Name>abcd</Name>
  79. </Author>
  80. <Author>
  81. <Name>acdsg</Name>
  82. </Author>
  83. <Author>
  84. <Name>bhah</Name>
  85. </Author>
  86. <Topic>hhkjj</Topic>
  87. <Year>2006</Year>
  88. <Month></Month>
  89. <Abstract-link></Abstract-link>
  90. <Full-Paper-link>ghh</Full-Paper-link>
  91. <Abstract>ggg</Abstract>
  92. <Conference>cncna</Conference>
  93. </Paper>
  94.  
  95.  
  96.  
  97. <Paper > <!--paper 1-->
  98. <Area>B</Area>
  99. <!--<Author>
  100. <Name>Ravi Sundaram</Name>
  101. </Author>-->
  102. <Author>
  103. <Name>abcd</Name>
  104. </Author>
  105. <Author>
  106. <Name>acdsg</Name>
  107. </Author>
  108. <Author>
  109. <Name>bhah</Name>
  110. </Author>
  111. <Topic>hhkjj</Topic>
  112. <Year>2006</Year>
  113. <Month></Month>
  114. <Abstract-link></Abstract-link>
  115. <Full-Paper-link>ghh</Full-Paper-link>
  116. <Abstract>ggg</Abstract>
  117. <Conference>cncna</Conference>
  118. </Paper>
  119.  
  120. <Paper > <!--paper 1-->
  121. <Area>B</Area>
  122. <!--<Author>
  123. <Name>Ravi Sundaram</Name>
  124. </Author>-->
  125. <Author>
  126. <Name>abcd</Name>
  127. </Author>
  128. <Author>
  129. <Name>acdsg</Name>
  130. </Author>
  131. <Author>
  132. <Name>bhah</Name>
  133. </Author>
  134. <Topic>hhkjj</Topic>
  135. <Year>2006</Year>
  136. <Month></Month>
  137. <Abstract-link></Abstract-link>
  138. <Full-Paper-link>ghh</Full-Paper-link>
  139. <Abstract>ggg</Abstract>
  140. <Conference>cncna</Conference>
  141. </Paper>
  142.  
  143.  
  144. <Paper > <!--paper 1-->
  145. <Area>B</Area>
  146. <!--<Author>
  147. <Name>Ravi Sundaram</Name>
  148. </Author>-->
  149. <Author>
  150. <Name>abcd</Name>
  151. </Author>
  152. <Author>
  153. <Name>acdsg</Name>
  154. </Author>
  155. <Author>
  156. <Name>bhah</Name>
  157. </Author>
  158. <Topic>hhkjj</Topic>
  159. <Year>2006</Year>
  160. <Month></Month>
  161. <Abstract-link></Abstract-link>
  162. <Full-Paper-link>ghh</Full-Paper-link>
  163. <Abstract>ggg</Abstract>
  164. <Conference>cncna</Conference>
  165. </Paper>
  166.  
  167.  
  168.  
  169. <Paper > <!--paper 1-->
  170. <Area>C</Area>
  171. <!--<Author>
  172. <Name>Ravi Sundaram</Name>
  173. </Author>-->
  174. <Author>
  175. <Name>abcd</Name>
  176. </Author>
  177. <Author>
  178. <Name>acdsg</Name>
  179. </Author>
  180. <Author>
  181. <Name>bhah</Name>
  182. </Author>
  183. <Topic>hhkjj</Topic>
  184. <Year>2006</Year>
  185. <Month></Month>
  186. <Abstract-link></Abstract-link>
  187. <Full-Paper-link>ghh</Full-Paper-link>
  188. <Abstract>ggg</Abstract>
  189. <Conference>cncna</Conference>
  190. </Paper>
  191.  
  192. </Publications>
  193.  
  194.  


Expand|Select|Wrap|Line Numbers
  1.  for Topic_Publications_xsl.xsl
Expand|Select|Wrap|Line Numbers
  1.  
  2. <?xml version="1.0" encoding="ISO-8859-1"?>
  3. <xsl:stylesheet version="1.0" 
  4. xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  5. xmlns:url="http://www.jclark.com/xt/java/java.net.URLEncoder"
  6.    exclude-result-prefixes="url">
  7.  
  8. <xsl:key name="rows" match="Paper" use="Area" />
  9. <xsl:template match="Publications">
  10.  
  11.  
  12. <html>
  13. <head>
  14. <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  15. <title>Ravi Sundaram-Publications</title>
  16. <link href="../css/stylesheet.css" rel="stylesheet" type="text/css" media="all" />
  17. </head>
  18. <body>
  19.  
  20. <font size="3">
  21. <xsl:apply-templates                        
  22.     select="Paper[generate-id(.) = generate-id(key('rows', Area)[1])]" >
  23.      <xsl:sort select="Area"/>            <!-- Select area alphabatecially. Group By-->
  24.  
  25.     </xsl:apply-templates>
  26. </font>
  27.  
  28. </body>
  29. </html>
  30.  
  31. </xsl:template>
  32.  
  33. <xsl:template match="Publications/Paper">
  34. <br/>
  35.  
  36. <b><xsl:value-of select="Area" /></b>            <!-- For each area selected above select all papers-->
  37. <br/>             
  38. <xsl:for-each select="key('rows', Area)">
  39. <xsl:sort select="Year" data-type="number" order="descending"/>
  40. <xsl:sort select="@monthid" data-type="number" order="descending"/>
  41. <br/>
  42.  
  43.    <xsl:choose>
  44.    <xsl:when test="string-length(Full-Paper-link)">       <!--if there is link to paper-->      
  45.    <a>
  46.    <xsl:attribute name="href"><xsl:value-of select="Full-paper-link"/> </xsl:attribute >
  47.    <span style="color: #0000ff">
  48.    <xsl:value-of select="Topic"/> 
  49.    </span>
  50.    </a>
  51.    <br/>
  52.    </xsl:when>
  53.    <xsl:otherwise>
  54.    <xsl:value-of select="Topic"/>                         <!--if there is no link to paper-->
  55.    <br/>
  56.    </xsl:otherwise>
  57.    </xsl:choose>
  58.  
  59.    <xsl:for-each select="Author">
  60.    <xsl:if test="string-length(Name)">
  61.    <xsl:if test="position()=1">
  62.    <xsl:text> with </xsl:text>
  63.    </xsl:if>
  64.  
  65.    <xsl:value-of select="Name"/>     
  66.    <xsl:if test="not(position()=last())">
  67.    <xsl:text>, </xsl:text>
  68.    </xsl:if>
  69.    <xsl:if test="position()=last()">
  70.    <br/>
  71.    </xsl:if>
  72.    </xsl:if> 
  73.    </xsl:for-each>
  74.    <xsl:value-of select="Conference"/>
  75.    <br/>
  76.    <xsl:if test="string-length(Abstract)">
  77.    <xsl:value-of select="Abstract"/>
  78.    <br/>
  79.    </xsl:if>
  80.    </xsl:for-each>
  81.  
  82. </xsl:template>
  83.  
  84.  
  85. </xsl:stylesheet>
  86.  
  87.  



Now if u run this code in an IE it works fine whereas it does not open up in Mozilla.

Kindly guide me.
Thanks
Mar 14 '07 #4
dorinbogdan
839 Expert 512MB
Hi,
Did you succeed to solve the problem ?
If yes, please let me know, in order to close the thread.
Thanks,
Dorin.
Mar 21 '07 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Eric | last post by:
I am trying to figure out a good way to implement a XSLT transformation. Basically my goal is that I want to be able to ouput the following XML in a document: <chart type="pie" width="100"...
3
by: Laiverd.COM | last post by:
Hi everybody, Since today the pages at http://www.laiverd.com/groundzero/anima have problems with the hover-styles in Netscape 7.1 (no problems in Mozilla, Firefox and IE on Windows). I am not...
15
by: IanUK | last post by:
I hope someone may be able to help please! Have a look at this site which I'm developing - http://tinyurl.com/6d4nr As you will see if you look at it in IE6, the browser has completely screwed...
2
by: anna | last post by:
Firefox Mozilla Browser Fonts / Format / rich text / webmail question I have Comcast. They do not support Firefox so they won't help me. When I use Mozilla firefox browser to access my web...
4
by: John Bullock | last post by:
Hello, I am at wit's end with an array sorting problem. I have a simple table-sorting function which must, at times, sort on columns that include entries with nothing but a space (@nbsp;). I...
5
by: niftyhawk | last post by:
Hi, Can anybody give me a simple example of how to Call Web Services from Mozilla based Browsers ? I can call web services from IE browser using web service behavior file, without any problems....
5
by: Jarson | last post by:
My JavaScript is trying to POST data to a CGI script (Perl) using XMLHttpRequest. My CGI server gets different data from IE than Mozilla Firefox. // For Mozilla, req = new XMLHttpRequest(); //...
23
by: AJBopp | last post by:
Ok, I'm trying to be a good little boy and create a site that doesn't use frames :) Things were going along decently until I uploaded what little I have done so far to the web server (that is,...
4
by: jwwest | last post by:
Hello all, I've been building a simple site based on XML, XSL and CSS in order to help me learn those technologies better. However, building a tableless page is brand new to me so I've run into...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.