• 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

Adding JSP Scriptlet in JSP Directive

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
<jsp:directive.include file='<%= session.getAttribute("htmlPath").toString(); %>' />


Hello I tried to add a Scriptlet in a jsp directive like above. But am keep getting the below error. Could anyone help on this??

HTTP Status 500 - /parseXML.jsp (line: 86, column: 1) File "<%= session.getAttribute("htmlPath").toString(); %>" not found

type Exception report

message /parseXML.jsp (line: 86, column: 1) File "<%= session.getAttribute("htmlPath").toString(); %>" not found

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

exception

org.apache.jasper.JasperException: /parseXML.jsp (line: 86, column: 1) File "<%= session.getAttribute("htmlPath").toString(); %>" not found
org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:42)
org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:443)
org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:133)
org.apache.jasper.compiler.Parser.processIncludeDirective(Parser.java:322)
org.apache.jasper.compiler.Parser.parseIncludeDirective(Parser.java:357)
org.apache.jasper.compiler.Parser.parseXMLDirective(Parser.java:533)
org.apache.jasper.compiler.Parser.parseFileDirectives(Parser.java:1764)
org.apache.jasper.compiler.Parser.parse(Parser.java:135)
org.apache.jasper.compiler.ParserController.doParse(ParserController.java:242)
org.apache.jasper.compiler.ParserController.parseDirectives(ParserController.java:119)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:193)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:373)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:353)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:340)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:657)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:357)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
 
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
<jsp:include page='<%= session.getAttribute("htmlPath").toString() %>'>

Hope this could help
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic