• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

URL-pattern in DD for jsp configuration

 
Anand Wadhwani
Ranch Hand
Posts: 151
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I specified pattern '/jspc*.jsp' for disabling scripting in JSPs matching with this pattern. When I started tomcat 5.0 server, I got following parsing error:

"Invalid <url-pattern> /jspc*.jsp in servlet mapping"

Could someone please help! Is the pattern I am specifying is incorrect, if so what's the correct pattern for disabling scripting for specific jsps.

Thanks!
 
Bhumika Thakkar
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
u can use a wildcard only in these 2 formats.
*.jsp or /jspc/*, combination would be /jspc/*.do...
 
Anand Wadhwani
Ranch Hand
Posts: 151
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Bhumika,

I moved my jsp in a folder and changed the DD also per your suggestion. I am still getting the same error:

Invalid <url-pattern> /jspfolder/*.jsp in servlet mapping

Are you able to disable scripting for selective JSPs? If so, how? What app server r u using? If tomcat, which version?

Thanks.
 
Bhumika Thakkar
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
make sure ur folder structure/ folder name is correct.

<root>
--> jspfolder

Scripting settings can only be specified in DD. Not the case with EL, we can use page directive to change the EL settings.

I use Websphere (practice at work).
 
Bhumika Thakkar
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
why is it saying servlet mapping??? <scripting-enabled> goes in <jsp-property-group> it has nothing to do with <servlet-mapping> element.

please paste ur dd.

Bhumika
 
Anand Wadhwani
Ranch Hand
Posts: 151
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here is the DD


and here is the JSP:


Thanks for your time.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic