cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Berin Loritsch" <blorit...@infoplanning.com>
Subject Cocoon 1.8 XSP and com.oreilly.servlet.MailMessage
Date Mon, 25 Sep 2000 20:10:40 GMT
I am trying to use the com.oreilly.servlet to send messages via SMTP
for my company's web site.  The response page for a form was working
until I add the following code:
------------------------------------------------------------
<xsp:structure>
  <xsp:include>java.io.PrintStream</xsp:include>
  <xsp:include>com.oreilly.servlet.MailMessage</xsp:include>
</xsp:structure>

<xsp:logic>
    MailMessage message = new MailMessage("mail.infoplanning.com");
    PrintStream out = message.getPrintStream();

    message.to(<request:get-parameter name="recipient"/>);
    message.setSubject(<request:get-parameter name="subject"/>);

    out.print(<request:get-parameter name="name"/>);
    out.print(" from ");
    out.println(<request:get-parameter name="company"/>);

    out.print("(email: ");
    out.print(<request:get-parameter name="email"/>);
    out.println(")");

    out.println("Requested the following document:");
    out.println(<request:get-parameter name="paper"/>);
    
    message.sendAndClose();
</xsp:logic>
-------------------------------------------------------------

I know consistently get the following message:

java.util.NoSuchElementException
 at org.apache.cocoon.Tokenizer.nextToken(Tokenizer.java:155)
 at org.apache.cocoon.processor.xsp.XSPUtil.split(XSPUtil.java:171)
 at org.apache.cocoon.processor.xsp.language.java.XSPJavaProcessor.compile(XSPJavaProcessor.java:133)
 at org.apache.cocoon.processor.xsp.XSPProcessor.process(XSPProcessor.java:489)
 at org.apache.cocoon.Engine.handle(Engine.java:359)
 at org.apache.cocoon.Cocoon.service(Cocoon.java:167)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
 at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:368)
 at org.apache.tomcat.core.Handler.service(Handler.java:261)
 at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:356)
 at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:720)
 at org.apache.tomcat.core.ContextManager.service(ContextManager.java:666)
 at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:194)
 at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:403)
 at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)
 at java.lang.Thread.run(Unknown Source)


---------------------------------------------------------
If you lust for Ham and Eggs, you have
committed breakfast in your heart
already.   -- C. S. Lewis


Mime
View raw message