it is:
package vstreet.turbine.myapp.modules.screens;
Thanks,
Dan
[EMAIL PROTECTED] wrote:
>Dan,
>
>what is the first line of your ServletInfo.java? It should read
>
>package vstreet.turbine.myapp.modules.screens;
>
>Bye,
>-Maik
>
>Dan Robinson <[EMAIL PROTECTED]> schrieb am 09.07.2002, 22:02:51:
>
>>Maik,
>>
>>No luck (frustrated gurgling noise #(*&#&(#@ ).
>>
>>My java files is:
>>
>>public class ServletInfo extends SecureScreen
>>{
>> /**
>> * Place all the data object in the context
>> * for use in the template.
>> */
>> public void doBuildTemplate( RunData data, Context context )
>> {
>> context.put("fooValue", "a Fool");
>> context.put("serverName", data.getRequest().getServerName());
>>// context.put("serverName", TurbineServlet.getServerName());
>> }
>>}
>>
>>My ServletInfo.vm is:
>>
>>Servlet Info:
>>
>>$serverName
>>
>>Foo Info: $fooValue
>>
>>Output is:
>>
>>Servlet Info: $serverName
>>Foo Info: $fooValue
>>
>>Velocity log shows:
>>
>>Tue Jul 09 12:58:20 PDT 2002 [warn]
>>org.apache.velocity.runtime.exception.ReferenceException: reference :
>>template = screens/ServletInfo.vm [line 3,column 1] : $serverName is not
>>a valid reference.
>>Tue Jul 09 12:58:20 PDT 2002 [warn]
>>org.apache.velocity.runtime.exception.ReferenceException: reference :
>>template = screens/ServletInfo.vm [line 5,column 14] : $fooValue is not
>>a valid reference.
>>
>>Dan
>>
>>
>>[EMAIL PROTECTED] wrote:
>>
>>>Hi Dan,
>>>
>>>your setup is ok, I experience the same problem. Seems like the
>>>ServletService is not being initialized correctly (allthough it claims
>>>initialization in the log).
>>>
>>>If you change ServletInfo.java to use data.getRequest().getServerName()
>>>instead of TurbineServlet.getServerName() it works. It is really the
>>>same if you look at the Turbine 2.1 sources...
>>>
>>>Take care,
>>>-Maik
>>>Dan Robinson schrieb am 09.07.2002, 20:25:10:
>>>
>>>>Maik,
>>>>
>>>>
>>>>Currently I've got:
>>>>
>>>>myapp\templates\app\screens\ServletInfo.vm
>>>>myapp\WEB-INF\classes\vstreet\turbine\myapp\modules\screens\ServletInfo.class
>>>>myapp\WEB-INF\src\java\vstreet\turbine\myapp\modules\screens\ServletInfo.java
>>>>
>>>>I have no idea what the "appropriate location" would be - this seems to
>>>>be the standard explained in the doco.
>>>>
>>>>Thanks for your assistance,
>>>>
>>>>Dan
>>>>
>>>>[EMAIL PROTECTED] wrote:
>>>>
>>>>>Hi Dan,
>>>>>
>>>>>>In 2.1 flavor of TDK the ServletInfo.vm outputs:
>>>>>>
>>>>>>Servlet Info: $serverName
>>>>>>
>>>>>The corresponding ServletInfo.java is not being found--it puts the
>>>>>variable "serverName" in the template's context.
>>>>>
>>>>>Copy the .java file to the appropriate location and modify the package
>>>>>name accordingly.
>>>>>
>>>>>HTH,
>>>>>-Maik
>>>>>
>>>>>--
>>>>>To unsubscribe, e-mail:
>>>>>For additional commands, e-mail:
>>>>>
>>>>>
>>>>>
>>>>
>>>>--
>>>>To unsubscribe, e-mail:
>>>>For additional commands, e-mail:
>>>>
>>>--
>>>To unsubscribe, e-mail:
>>>For additional commands, e-mail:
>>>
>>>
>>>
>>
>>
>>--
>>To unsubscribe, e-mail:
>>For additional commands, e-mail:
>>
>
>--
>To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
>For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
>
>
>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>