Hi,
I'm posting this question a second time...I think I need to be more
specific.
I'm using Turbine 2.1. I've gotten the sample 'newapp' working with MySql
on W2K and have figured out how to add my own templates and screens to it.
So far so good.
But I'm having problems calling actions. In my experimental "HelloWorld.vm"
template, I'm trying to call my action, called "SayHello" (guess what it
does). I read the docs and followed how the other sample 'newapp' actions
were written.
The code looks like this...
<SNIP>
package org.mycompany.newapp.modules.actions;
import org.apache.velocity.context.Context;
import org.apache.turbine.util.RunData;
import org.apache.turbine.modules.actions.VelocityAction;
class SayHello extends VelocityAction
{
public void doPerform(RunData data, Context context)
{
context.put("sayhello", "Hello World");
}
}
</SNIP>
Not very exciting, but it suits my point. I run "ant compile" and the class
gets successfully put into
...\WEB-INF\classes\org\mycompany\newapp\modules\actions\SayHello.class
along with all the other sample action classes.
My template calls the action with an href like this:
<a
href="http://localhost:8080/newapp/servlet/newapp/template/HelloWorld.vm/act
ion/SayHello">Say Hello:</a> $!sayhello
When I click the link, I get the standard error template back. So I go
check the ...\newapp\logs\turbine.log, and I see this:
Turbine.handleException:
Requested Action not found: Counter
Turbine looked in the following modules.packages path:
[org.mycompany.newapp.modules, org.apache.turbine.flux.modules,
org.apache.turbine.modules]
That's about it. It smells like a classpath issue to me, but then all the
example action work, so what gives? I've looked at it long and hard, but
can't figure it out. Can somebody please give me some advice?
Thanks,
Philip
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]