aspose file tools*
The moose likes Other Application Frameworks and the fly likes Mapping URL's to files Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Frameworks » Other Application Frameworks
Bookmark "Mapping URL Watch "Mapping URL New topic
Author

Mapping URL's to files

Johnny Gara
Ranch Hand

Joined: Mar 09, 2007
Posts: 43
using spring2.5, and just trying to map a url to a file

ie.
http://localhost:8080/myapp/testme/yahyou

I want it to actually retrieve
http://localhost:8080/myapp/results/yahyou.xml

I know how I'd do it if I was generating my xml file, but if the file exists I can't seem to make it work. I tried implementing the UrlFilenameViewController and basically



and while it will return what I think I want (ie, with a prefix=results, a suffix=.xml, i get /results/youwin.xml) but I get an exception:

org.apache.tiles.definition.NoSuchDefinitionException: /results/youwin.xml
Sachin Joshi
Ranch Hand

Joined: Aug 06, 2008
Posts: 83

Try making it



instead of



Web Development Tips and Tutorials - By Sachin
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Mapping URL's to files
 
Similar Threads
How to access gif files from servelets
A Servlet That Uses Packages and Utilities
Tomcat 404 error
Running servlet in tomcat
Tomcat 404 Error - Still not working