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 <jsp:include work correctly with this scenario?
>
> 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




Reply via email to