I experienced problem as tomcat open .xml file with .css. I used tomcat only, without apatch, when url typed into the browser, it only showed .xml context with.css format. Anyone know what is wrong?
Support for xml document viewing in browsers is not the same between browsers. What one are you using? and what does the code look like that produces the XML response? Or are you browsing to an XML file directly?
Sorry Mike, What I want to said is that if I open XML as file with browser, the context and style all correct, but if I access through tomcat with URL typed in browser, only context display correctly without style. And I did both with same computer and same broswer.
home.ccs as the following; page { background-color: #ffff00; width: 100%; } title { display: block; margin-bottom: 30pt; margin-left: 0; font-size: 50pt; } para { color: #FF0000; font-size: 20pt; } ---------------------------- And, home.xml as the following <?xml version="1.0"?> <?xml-stylesheet href="home.css" type="text/css"?> <page> <title>XML Home Page</title> <para>Welcome to one of the few Home Pages written in XML, A technology will let programmers lost job, revenge ...</para> </page>
Another one here shows how to do what you are trying, with the css style sheet. It looks to me like you've done everything the same as they have http://www.w3schools.com/xml/xml_display.asp
Perhaps you are using a browser that just doesn't understand what to do with an xml document?