org.xml.sax.SAXParseException: Content is not allowed in prolog.

157 views
Skip to first unread message

idan...@gmail.com

unread,
May 7, 2007, 5:01:13 PM5/7/07
to Google Web Toolkit
Hello,
When I am trying to run my GWT application I gets the follwoing
exception

[ERROR] Failure while parsing XML
org.xml.sax.SAXParseException: Content is not allowed in prolog.
at
org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:
1183)
at com.google.gwt.dev.util.xml.ReflectiveParser
$Impl.parse(ReflectiveParser.java:295)
at com.google.gwt.dev.util.xml.ReflectiveParser$Impl.access
$100(ReflectiveParser.java:48)
at
com.google.gwt.dev.util.xml.ReflectiveParser.parse(ReflectiveParser.java:
366)
at
com.google.gwt.dev.cfg.ModuleDefLoader.nestedLoad(ModuleDefLoader.java:
175)
at com.google.gwt.dev.cfg.ModuleDefLoader.load(ModuleDefLoader.java:
208)
at
com.google.gwt.dev.cfg.ModuleDefLoader.loadFromClassPath(ModuleDefLoader.java:
81)
at
com.google.gwt.dev.shell.GWTShellServlet.getModuleDef(GWTShellServlet.java:
476)
at
com.google.gwt.dev.shell.GWTShellServlet.doGetPublicFile(GWTShellServlet.java:
351)
at
com.google.gwt.dev.shell.GWTShellServlet.processFileRequest(GWTShellServlet.java:
149)
at
com.google.gwt.dev.shell.GWTShellServlet.doGet(GWTShellServlet.java:
104)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)


Some one know why? and what do I need to do to fix it?

Thanks,
Idan

jhulford

unread,
May 8, 2007, 9:45:35 AM5/8/07
to Google Web Toolkit
Generally you'll get something like that if you forgot to close an XML
element. Probably one of your .gwt.xml files?

idan...@gmail.com

unread,
May 8, 2007, 3:20:28 PM5/8/07
to Google Web Toolkit
Hi Again,
My menu.gwt.xml file is:
<module>
<inherits name="com.google.gwt.user.User"/>
<entry-point class="com.mycompany.client.menu"/>
<servlet path="/Serv" class="com.mycompany.project.server.ServImpl"/>
<inherits name="com.google.gwt.i18n.I18N"/>
<extend-property name="locale" values="fr,iw,iw"/>
</module>

and it still not working - I get the same exception:
[Fatal Error] :1:1: Content is not allowed in prolog.

Please tell me what wrong or what else can be wrong
Thanks,
Idan

> > com.google.gwt.dev.cfg.ModuleDefLoader.loadFromClassPath(ModuleDefLoader.ja­va:


> > 81)
> > at
> > com.google.gwt.dev.shell.GWTShellServlet.getModuleDef(GWTShellServlet.java:
> > 476)
> > at

> > com.google.gwt.dev.shell.GWTShellServlet.doGetPublicFile(GWTShellServlet.ja­va:
> > 351)
> > at
> > com.google.gwt.dev.shell.GWTShellServlet.processFileRequest(GWTShellServlet­.java:


> > 149)
> > at
> > com.google.gwt.dev.shell.GWTShellServlet.doGet(GWTShellServlet.java:
> > 104)
> > at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
>
> > Some one know why? and what do I need to do to fix it?
>
> > Thanks,

> > Idan- Hide quoted text -
>
> - Show quoted text -

Mark Volkmann

unread,
May 8, 2007, 3:47:15 PM5/8/07
to Google-We...@googlegroups.com
Are you sure there are no characters before the "<" in your
"<module>" start tag?
The prolog section of the XML is everything before that and it's
saying it's finding invalid content there.

>>> (ModuleDefLoader.ja va:
>>> 81)
>>> at
>>> com.google.gwt.dev.shell.GWTShellServlet.getModuleDef
>>> (GWTShellServlet.java:
>>> 476)
>>> at
>>> com.google.gwt.dev.shell.GWTShellServlet.doGetPublicFile
>>> (GWTShellServlet.ja va:
>>> 351)
>>> at
>>> com.google.gwt.dev.shell.GWTShellServlet.processFileRequest
>>> (GWTShellServlet .java:

idan...@gmail.com

unread,
May 8, 2007, 5:17:16 PM5/8/07
to Google Web Toolkit
I have nothing before <module> or after the </module>
The tag <module> if the first charicter in this page
Do you have another Idea?
Could it be because my Java classes? (on java to JavaScript
compilation or something like that?)

On May 8, 10:47 pm, Mark Volkmann <m...@ociweb.com> wrote:
> Are you sure there are no characters before the "<" in your
> "<module>" start tag?
> The prolog section of the XML is everything before that and it's
> saying it's finding invalid content there.
>

> >> - Show quoted text -- Hide quoted text -

idan...@gmail.com

unread,
May 8, 2007, 6:11:45 PM5/8/07
to Google Web Toolkit
Hello!!!
Strange thing with Notepad & with Edit-Plus editors it looks like the
<module> was the firt thing in the file
BUT!
with XML Editor I dowlnoaded I found: "ן»¿<module>" so now I removed
by this editor the "ן»¿" and it works!

Thanks!!!
Idan

Reply all
Reply to author
Forward
0 new messages