E
Earth
Hi all,
I am new in JSP and Tomcat. Please forgive me if I have raised a simple question.
I am trying to write a simple JSP in XML syntax as follows.
<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
version="1.2">
<html><body>
<jsp:directive.page language="java" />
<jsp:declaration>
int count = 0;
</jsp:declaration>
<jsp:scriptlet>
count++;
</jsp:scriptlet>
<br>
<jsp:text>
Welcome! You are visitor number
</jsp:text>
<jsp:expression>
count
</jsp:expression>
</br>
</body></html>
</jsp:root>
However, when I access the page with IE6, I get the HTML tags in the browser.
- <html>
- <body>
<br>Welcome! You are visitor number 1</br>
</body>
</html>
It is ok when using the stand JSP syntax, for example <% %>
Do I missing anythiing here?
Please enlighten me.
Thanks in advance for any ideas or inputs.
eclifeww
I am new in JSP and Tomcat. Please forgive me if I have raised a simple question.
I am trying to write a simple JSP in XML syntax as follows.
<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
version="1.2">
<html><body>
<jsp:directive.page language="java" />
<jsp:declaration>
int count = 0;
</jsp:declaration>
<jsp:scriptlet>
count++;
</jsp:scriptlet>
<br>
<jsp:text>
Welcome! You are visitor number
</jsp:text>
<jsp:expression>
count
</jsp:expression>
</br>
</body></html>
</jsp:root>
However, when I access the page with IE6, I get the HTML tags in the browser.
- <html>
- <body>
<br>Welcome! You are visitor number 1</br>
</body>
</html>
It is ok when using the stand JSP syntax, for example <% %>
Do I missing anythiing here?
Please enlighten me.
Thanks in advance for any ideas or inputs.
eclifeww