Re: Problems with Taglibs
- From: GArlington <garlington@xxxxxxxxxxxxx>
- Date: Thu, 31 Jan 2008 03:43:40 -0800 (PST)
On Jan 30, 12:43 pm, "gwoodho...@xxxxxxxxx" <gwoodho...@xxxxxxxxx>
wrote:
Hello all,
Please help me! Im so tired of having taglibs in one way or another
trying to stop me doing some serious programming!
I'm getting this error:
javax.servlet.ServletException: javax.servlet.jsp.JspException:
Content is not allowed in prolog.
I have: "WEB-INF\lib\standard-1.1.2-patched.jar" in my buildpath.
The part of the code its having trouble with is in my very first page
with this:
<%@ include file="/WEB-INF/jsp/common/taglibs.jsp" %>
which links to taglibs.jsp:
I think that the following line(s) may be causing your problem:
<%@ page contentType="text/html;charset=UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
You may be trying to reset the page headers after some output is
already written, it does not usually work...
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"
%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="c-rt" uri="http://java.sun.com/jstl/core_rt" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="x" uri="http://java.sun.com/jsp/jstl/xml" %>
<%@ taglib prefix="html" uri="http://jakarta.apache.org/struts/tags-
html" %>
<%@ taglib prefix="html-el" uri="http://jakarta.apache.org/struts/tags-
html-el" %>
<%@ taglib prefix="bean" uri="http://jakarta.apache.org/struts/tags-
bean" %>
<%@ taglib prefix="bean-el" uri="http://jakarta.apache.org/struts/tags-
bean-el" %>
<%@ taglib prefix="str" uri="http://jakarta.apache.org/taglibs/
string-1.1" %>
Now i know this exact same source code works for other people who are
using it as a base, so i must assume this is some sort of
configuration problem.
Could someone pretty please tell me what this error message can be
caused by because i can't find any way to fix it.
Thanks in advance to any guru's out there that can help me
Graeme
.
- Follow-Ups:
- Re: Problems with Taglibs
- From: Lew
- Re: Problems with Taglibs
- References:
- Problems with Taglibs
- From: gwoodhouse@xxxxxxxxx
- Problems with Taglibs
- Prev by Date: Re: return result to php
- Next by Date: Re: return result to php
- Previous by thread: Problems with Taglibs
- Next by thread: Re: Problems with Taglibs
- Index(es):