Hi Manish,

> How can I handle the condition gracefully that file specified by$fileName
> does not exist in either -
> 
> #include($fileName)
> #parse($fileName)
If you know the $fileName prior to the template handling, you can use
the templateExists() method and check.  I believe in 1.4 they are called
resourceExists().
    
http://jakarta.apache.org/velocity/api/org/apache/velocity/app/VelocityEngine.html#templateExists(java.lang.String)
    
http://jakarta.apache.org/velocity/api/org/apache/velocity/app/Velocity.html#templateExists(java.lang.String)

Best regards,
-- Shinobu Kawai

--
Shinobu Kawai <[EMAIL PROTECTED]>


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to