| Author |
|
johnmiller Newbie

Joined: 03 November 2009
Online Status: Offline Posts: 8
|
| Posted: 03 November 2009 at 4:00pm | IP Logged
|
|
|
hello all, we have our website coming up in tomcat and the url's are really big and lot of techno stuff.
ex tomcat url: http://abcdef.com/xps/rde/mchg/capitalpart/hs/Home.htm
we obviously do not want this. this should in turn be http://abcdef.com/home.htm where abcdef.com is dns name and it will port 80 of IIS wherein Ape will be doing transformation.
when i tried Ape it just redirects and also changes the url.
is there any tool in helicon that does not only redirect but also changes context as below.
RewriteRule http://abcdef.com/xps/rde/mchg/capitalpart/hs/Home.htm http://abcdef.com/Home.htm [NC,L]
or to ask the dumb question: is there any tool which will hide the url or give nicer url we want (not just one static url) for every link. will link freeze do the job?
|
| Back to Top |
|
| |
Anton Admin Group

Joined: 30 January 2007 Location: Ukraine
Online Status: Offline Posts: 10520
|
| Posted: 04 November 2009 at 4:38am | IP Logged
|
|
|
LinkFreeze can make your dynamic URLs static but it can't rewrite them to look more pretty (as you outlined above).
The best solution for you is Helicon Ape or ISAPI_Rewrite.
"but also changes context as below" - do you mean you want to change links on pages as well?
Then you may consider using Helicon Ape mod_replace module.
__________________ Regards,
Anton
|
| Back to Top |
|
| |
johnmiller Newbie

Joined: 03 November 2009
Online Status: Offline Posts: 8
|
| Posted: 04 November 2009 at 10:00am | IP Logged
|
|
|
thanks anton..
this is the issue: we have our website on tomcat and the url's are lengthy like below
http://abcdef:8080/conpos/rde/xichg/pages/hs/1237.htm
http://abcdef:8080/conpos/rde/xichg/pages/hs/Home.htm
now, we have on port 80 in IIS redirector set to redirect traffic to tomcat (on ajp).
but the url is lengthy as you can see above. using redirection we can hit below url (instead of 8080) but still url are lengthy.
http://abcdef/conpos/rde/xichg/pages/hs/1237.htm
we want url to be http://abcdef/conpos/1237.htm or http://abcdef/Home.htm, etc intead of lengthy url's.
will mod replace or any other tool in helicon do this.
thanks for your response.
|
| Back to Top |
|
| |
johnmiller Newbie

Joined: 03 November 2009
Online Status: Offline Posts: 8
|
| Posted: 04 November 2009 at 10:01am | IP Logged
|
|
|
note that in above post, although url is changed the content comes from original place. for the end user he see the url in short form but content is beign fetched from its original plac (which is the lengthy url location).
|
| Back to Top |
|
| |
Anton Admin Group

Joined: 30 January 2007 Location: Ukraine
Online Status: Offline Posts: 10520
|
| Posted: 05 November 2009 at 2:34am | IP Logged
|
|
|
Please try to use the following rules just to make sure it's working for the cases you provided above:
RewriteBase /
RewriteRule ^conpos/rde/xichg/pages/hs/1237\.htm$ conpos/1237.htm [NC,R=301,L]
RewriteRule ^conpos/1237\.htm$ conpos/rde/xichg/pages/hs/1237.htm [NC,L]
RewriteRule ^conpos/rde/xichg/pages/hs/Home\.htm$ Home.htm [NC,R=301,L]
RewriteRule ^Home\.htm$ conpos/rde/xichg/pages/hs/Home.htm [NC,L]
__________________ Regards,
Anton
|
| Back to Top |
|
| |
johnmiller Newbie

Joined: 03 November 2009
Online Status: Offline Posts: 8
|
| Posted: 07 November 2009 at 12:08am | IP Logged
|
|
|
wonderful anton. i will check and let you know. hopefully the url stays as home.htm and not give the entire cps/hfs/etc kind of thing.
|
| Back to Top |
|
| |
johnmiller Newbie

Joined: 03 November 2009
Online Status: Offline Posts: 8
|
| Posted: 07 November 2009 at 9:00pm | IP Logged
|
|
|
Hello Anton, i don't think it works.
I have 2 points (pl. see rule at end); 1. the foo rule below works correctly. If I say http://server/foo.htm it takes me to the big url and the url displays big naturally.
2. the second (rule 2 and 3) rule does not work. If i say http://server/Home.htm nothing happens.
My situation is more clear now for me. I will explain it below. 1. All url's are big and of format as http://abcedef.com/conpos/rde/xichg/pages/hs/3119.htm ; http://abcedef.com/conpos/rde/xichg/pages/hs/8978.htm ; http://abcedef.com/conpos/rde/xichg/pages/hs/7890.htm ; http://abcedef.com/conpos/rde/xichg/pages/hs/7654.htm (and we have got home at http://abcedef.com/conpos/rde/xichg/pages/hs/Home.htm)
2. As you can see all url's are different only in the number like 7890, 7654, etc.
3. Now what I want a small url like http://abcedef.com/3119.htm or http://abcedef.com/7890.htm or http://abcedef.com/Home.htm.
4. The content should come correct and also importantly url also should display only small url.
Are these possible with any Helicon product?
Thanks, John.
# Helicon Ape version 3.0.0.28
RewriteEngine On #RewriteRule . - [F] RewriteRule ^foo\.htm$ http://abcdef.com/conpos/rde/xichg/pages/hs/3130.htm [NC,L]
RewriteBase / RewriteRule ^conpos/rde/xichg/pages/hs\.htm$ Home.htm [NC,R=301,L] RewriteRule ^Home\.htm$ ^conpos/rde/xichg/pages/hs/Home.htm [NC,L]
|
| Back to Top |
|
| |
Anton Admin Group

Joined: 30 January 2007 Location: Ukraine
Online Status: Offline Posts: 10520
|
| Posted: 10 November 2009 at 6:20am | IP Logged
|
|
|
Yes, sure it's possible with Ape (I see you are using it). Please try to use the following rules:
RewriteEngine On
RewriteBase /
RewriteRule ^conpos/rde/xichg/pages/hs/(\d+|Home)\.htm$ $1.htm [NC,R=301,L]
RewriteRule ^(\d+|Home)\.htm$ ^conpos/rde/xichg/pages/hs/$1.htm [NC,L]
If it doesn't work, please enable logging and provide rewrite log records for the specific non-working request.
__________________ Regards,
Anton
|
| Back to Top |
|
| |
johnmiller Newbie

Joined: 03 November 2009
Online Status: Offline Posts: 8
|
| Posted: 10 November 2009 at 3:26pm | IP Logged
|
|
|
That does not work Anton. But let me step back.
I want foo to go to amazon.com and abc.htm to google.com. But i also do not want the url to change. Meaning when I say http://localhost/foo.htm, google should be displayed but the url should still be same (which is foo.htm).
is this possible. If so, then it solves my case as I can give 1234.htm and redirect to my big url and the content comes but the url still displays 1234.htm.
Thanks.
RewriteEngine On RewriteBase / RewriteRule ^foo\.htm$ http://www.amazon.com [NC,L] RewriteRule ^abc\.htm$ http://www.google.com [NC,L]
|
| Back to Top |
|
| |
Anton Admin Group

Joined: 30 January 2007 Location: Ukraine
Online Status: Offline Posts: 10520
|
| Posted: 13 November 2009 at 5:46am | IP Logged
|
|
|
Yesm it's possible using proxy functionality which is enabled by P flag:
RewriteEngine On
RewriteBase /
RewriteRule ^foo\.htm$ http://www.amazon.com [NC,P]
RewriteRule ^abc\.htm$ http://www.google.com [NC,P]
__________________ Regards,
Anton
|
| Back to Top |
|
| |