• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

problem with EL functions

 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am learning EL function from HFSJ 2nd edition and using tomcat 6.0.14 web server.
I had tried one example in HFSJ for roll-dice but following error message appears:
HTTP Status 500 -

--------------------------------------------------------------------------------

type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

org.apache.jasper.JasperException: File "/DiceFunctions" not found
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:51)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:409)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:116)
org.apache.jasper.compiler.TagLibraryInfoImpl.<init>(TagLibraryInfoImpl.java:160)
org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:420)
org.apache.jasper.compiler.Parser.parseDirective(Parser.java:476)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1426)
org.apache.jasper.compiler.Parser.parse(Parser.java:133)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:216)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:103)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:167)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:306)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:317)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

I have used three files in this example exactly same as given in HFSJ at page 393.
1) myfunction.tld

2) DiceRoller.java

3)TestRoll.jsp


[ May 22, 2008: Message edited by: vaibhav kumar srivastava ]
[ May 23, 2008: Message edited by: vaibhav kumar srivastava ]
 
Sheriff
Posts: 67748
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please be sure to use UBB code tags when posting code to the forums. Unformatted code is extermely hard to read and many people that might be able to help you will just move along. Please read this for more information.

You can go back and change your post to add code tags by clicking the .
 
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Vaibhav,

Javaranch always suggests to use UBB code tags for posting code.




The above part of the exception clearly says that there is some thing wrong with the configuration. Please go though the following check list.
1) What is the extension of the tld file..?? It should be .tld

2) Where is it placed..?? Should be in in your WEB-INF folder.

3) Where is your java class?? It should be under in the dierctory /WEB-INF/class/foo.

4) If all the above are ok, try restarting your server. Coz this time it may detect the tld and deploy it.

[ May 23, 2008: Message edited by: Prasad Tamirisa ]
 
vaibhav srivastava
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

The above part of the exception clearly says that there is some thing wrong with the configuration. Please go though the following check list.

1) What is the extension of the tld file..?? It should be .tld

2) Where is it placed..?? Should be in in your WEB-INF folder.

3) Where is your java class?? It should be under in the dierctory /WEB-INF/class/foo.

4) If all the above are ok, try restarting your server. Coz this time it may detect the tld and deploy it.


Thanks Durga prasad
I had adhered to checklist given by you but still same problem persist.
Is it a version problem or what?? i don't understand. If you can please try on your computer and confirm me. So if there any need to reinstall my tomcat.
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Vaibhav,

You probably already solved the problem already but i noticed that in your post you wrote in the tld file



i.e. you mispelt the closing tag.

its always little things ;)
 
reply
    Bookmark Topic Watch Topic
  • New Topic