RE: How can I simplify a URL?
I decided to take Scott's Farquhar approach to url simplification, here is what I decided on: http://www.myprofiles.com/member/profile/apara_personal Other options were viable but I did not choose them for the following reasons: 1. A filter would have difficulties distinguishing between IMG and other types of requests 2. Using HTTP error 404 page to attempt to read the profile did not seem clean 3. Using a virtual server along with response.sendRedirect(new server) would have exposed the virtual server to the user. I did not want to do this, since once the user gets to the virtual server it's difficult to return back to the original. Besides, now I would have to maintain two different applications. Thanks for all your help. -AP_ http://www.alexparansky.com Java/J2EE Architect/Consultant http://www.myprofiles.com/member/profile/apara_personal -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Scott Farquhar Sent: Thursday, April 18, 2002 3:04 AM To: Orion-Interest Subject: Re: How can I simplify a URL? Just have one directory level. eg: http://view.myprofiles.com/p/127 Then map the servlet to /p* That avoids problems with images. Cheers, Scott Alex Paransky wrote: > I have a url which looks like this: > > http://www.myprofiles.com/view.do?profileId=127 > > I would like to be able to replace it with: > > http://view.myprofiles.com/127 > > I know how to create a new website with view.myprofiles being serviced by > orion. I am just not sure how to map the /127 to execute > /view.do?profileId=127. > > I was thinking of mapping a servlet to "/" context, however, the concern I > have is that if there are any images I don't want to servlet to process > them. Also, will the > Thanks for any suggestions. > > -AP_ > http://www.alexparansky.com > Java/J2EE Architect/Consultant > http://www.myprofiles.com/member/view.do?profileId=127 > > > -- Scott Farquhar :: [EMAIL PROTECTED] Atlassian :: http://www.atlassian.com Supporting YOUR J2EE World
Re: How can I simplify a URL?
how does this obfuscation "simplify" the processing? > I have a url which looks like this: > > http://www.myprofiles.com/view.do?profileId=127 > > I would like to be able to replace it with: > > http://view.myprofiles.com/127 > > I know how to create a new website with view.myprofiles being serviced by > orion. I am just not sure how to map the /127 to execute > /view.do?profileId=127. > > I was thinking of mapping a servlet to "/" context, however, the concern I > have is that if there are any images I don't want to servlet to process > them. Also, will the > Thanks for any suggestions. > > -AP_ > http://www.alexparansky.com > Java/J2EE Architect/Consultant > http://www.myprofiles.com/member/view.do?profileId=127 > >
RE: How can I simplify a URL?
Ideas: 1) Create a filter to handle this. OR 2) Use an error page for HTTP error 404 which redirects or includes HTH, Juan Pablo Lorandi Chief Software Architect Code Foundry Ltd. [EMAIL PROTECTED] Barberstown, Straffan, Co. Kildare, Ireland. Tel: +353-1-6012050 Fax: +353-1-6012051 Mobile: +353-86-2157900 www.codefoundry.com > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]] On Behalf Of > Alex Paransky > Sent: Thursday, April 18, 2002 7:07 AM > To: Orion-Interest > Subject: How can I simplify a URL? > > > I have a url which looks like this: > > http://www.myprofiles.com/view.do?profileId=127 > > I would like to be able to replace it with: > http://view.myprofiles.com/127 I know how to create a new website with view.myprofiles being serviced by orion. I am just not sure how to map the /127 to execute /view.do?profileId=127. I was thinking of mapping a servlet to "/" context, however, the concern I have is that if there are any images I don't want to servlet to process them. Also, will the http://www.alexparansky.com Java/J2EE Architect/Consultant http://www.myprofiles.com/member/view.do?profileId=127
Re: How can I simplify a URL?
Just have one directory level. eg: http://view.myprofiles.com/p/127 Then map the servlet to /p* That avoids problems with images. Cheers, Scott Alex Paransky wrote: > I have a url which looks like this: > > http://www.myprofiles.com/view.do?profileId=127 > > I would like to be able to replace it with: > > http://view.myprofiles.com/127 > > I know how to create a new website with view.myprofiles being serviced by > orion. I am just not sure how to map the /127 to execute > /view.do?profileId=127. > > I was thinking of mapping a servlet to "/" context, however, the concern I > have is that if there are any images I don't want to servlet to process > them. Also, will the > Thanks for any suggestions. > > -AP_ > http://www.alexparansky.com > Java/J2EE Architect/Consultant > http://www.myprofiles.com/member/view.do?profileId=127 > > > -- Scott Farquhar :: [EMAIL PROTECTED] Atlassian :: http://www.atlassian.com Supporting YOUR J2EE World