You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Norman Khine <no...@khine.net> on 2006/12/15 13:19:14 UTC
[users@httpd] Mod re-write help
Hello,
I would like to know how to turn this URI
http://destinationsguide.info/catalogue/c51/c57?b_start=15
into something like
http://destinationsguide.info/catalogue/africa/eastern-africa.html
I am already using one rewrite into Zope, so I am not sure how to proceed.
<VirtualHost *:80>
ServerName destinationsguide.info
ServerAlias www.destinationsguide.info
RewriteEngine On
#RewriteCond %{HTTP_HOST} ^www\.destinationsguide\.info [nc]
#RewriteRule (.*) http://destinationsguide.info [R=301,C]
RewriteRule ^/(.*)
http://destinationsguide.info:15080/VirtualHostBase/http/destinationsguide.info:80/destinations/VirtualHostRoot/$1
[L,P]
Thanks
Norman
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] Mod re-write help
Posted by Norman Khine <no...@khine.net>.
Joshua Slive wrote:
> On 12/15/06, Norman Khine <no...@khine.net> wrote:
>> Hello,
>>
>> I would like to know how to turn this URI
>>
>> http://destinationsguide.info/catalogue/c51/c57?b_start=15
>>
>> into something like
>>
>> http://destinationsguide.info/catalogue/africa/eastern-africa.html
>>
>> I am already using one rewrite into Zope, so I am not sure how to
>> proceed.
>>
>> <VirtualHost *:80>
>> ServerName destinationsguide.info
>> ServerAlias www.destinationsguide.info
>> RewriteEngine On
>> #RewriteCond %{HTTP_HOST} ^www\.destinationsguide\.info [nc]
>> #RewriteRule (.*) http://destinationsguide.info [R=301,C]
>> RewriteRule ^/(.*)
>> http://destinationsguide.info:15080/VirtualHostBase/http/destinationsguide.info:80/destinations/VirtualHostRoot/$1
>>
>> [L,P]
>
> The problem is a little under-specified. What do you mean by "turn
> into"? Do you expect people to use the "pretty" url, and then you
> will internally send them to Zope using the less-pretty one? Or do
> you want to externally redirect between them so that people enter the
> less-pretty url and then their browser location bar changes?
>
> In addition, it is unclear how you expect the mapping between the two
> urls to work in general. Do you have a list that maps one form to the
> other?
>
> Joshua.
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server
> Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
Hi Joshua,
I wanted to make the URL's google /index engine search friendly -
whether this is possible, I am not sure ;(
My idea was to use the Page header and use this as the mapping, but I
can see the problem now...
Forget I asked...
By the way, how do I make this to work
#RewriteCond %{HTTP_HOST} ^www\.destinationsguide\.info [nc]
#RewriteRule (.*) http://destinationsguide.info [R=301,C]
When I uncomment the code the second RewriteRule is not taken into account
Cheers
Norman
--
Norman Khine
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] Mod re-write help
Posted by Norman Khine <no...@khine.net>.
Germer, Carsten wrote:
> Heya Norman,
> this is a Zope problem, or even more of the Content Management System
> (Plone, ZMS etc.) you use within Zope.
> I had the same problem and it turned out that you have to have the logic
> that maps between the "pretty URLs" and your object-ids within Zope.
> You can not rely on Apache to solve that unless you want to maintain a
> _huge_ list of rewrite rules.
> Fortunately our CMS "ZMS" has such a logic which we're using now.
> I think if you turn to the mailing list for your CMS you should have a
> solution very quickly.
>
> Cheers /Carsten
>
> ------------------------------------------------------------------------
> Carsten Germer Deutsches Elektronen Synchrotron (Web-Office, IT)
> phone: +49-40-8998-1661 Notkestr. 85
> web: http://wof.desy.de 22607 Hamburg
> e-mail: carsten.germer@desy.de Germany
> ------------------------------------------------------------------------
>
>
>> -----Original Message-----
>> From: jslive@gmail.com [mailto:jslive@gmail.com] On Behalf Of
>> Joshua Slive
>> Sent: Friday, December 15, 2006 2:53 PM
>> To: users@httpd.apache.org
>> Subject: Re: [users@httpd] Mod re-write help
>>
>>
>> On 12/15/06, Norman Khine <no...@khine.net> wrote:
>>
>>> Hello,
>>>
>>> I would like to know how to turn this URI
>>>
>>> http://destinationsguide.info/catalogue/c51/c57?b_start=15
>>>
>>> into something like
>>>
>>> http://destinationsguide.info/catalogue/africa/eastern-africa.html
>>>
>>> I am already using one rewrite into Zope, so I am not sure
>>>
>> how to proceed.
>>
>>> <VirtualHost *:80>
>>> ServerName destinationsguide.info
>>> ServerAlias www.destinationsguide.info
>>> RewriteEngine On
>>> #RewriteCond %{HTTP_HOST} ^www\.destinationsguide\.info [nc]
>>> #RewriteRule (.*) http://destinationsguide.info [R=301,C]
>>> RewriteRule ^/(.*)
>>>
>>>
>> http://destinationsguide.info:15080/VirtualHostBase/http/destin
>>
> ationsguide.info:80/destinations/VirtualHostRoot/$1
>
>> [L,P]
>>
>
> The problem is a little under-specified. What do you mean by "turn
> into"? Do you expect people to use the "pretty" url, and then you
> will internally send them to Zope using the less-pretty one? Or do
> you want to externally redirect between them so that people enter the
> less-pretty url and then their browser location bar changes?
>
> In addition, it is unclear how you expect the mapping between the two
> urls to work in general. Do you have a list that maps one form to the
> other?
>
> Joshua.
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server
> Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
>
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
> " from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org
>
>
>
Hi Carsten,
Thanks for the advice, much appreciated. What is the logic with the ZMS
used to map this, is there an external python method? For now I am using
the Bizar Shop, as I will be linking this to a payment system, but maybe
will change, is still early.
By the way the http://www.zms-publishing.com seems cool, how do you
compare to Plone for example?
Cheers
Norman
--
Norman Khine
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
RE: [users@httpd] Mod re-write help
Posted by "Germer, Carsten" <ca...@desy.de>.
Heya Norman,
this is a Zope problem, or even more of the Content Management System
(Plone, ZMS etc.) you use within Zope.
I had the same problem and it turned out that you have to have the logic
that maps between the "pretty URLs" and your object-ids within Zope.
You can not rely on Apache to solve that unless you want to maintain a
_huge_ list of rewrite rules.
Fortunately our CMS "ZMS" has such a logic which we're using now.
I think if you turn to the mailing list for your CMS you should have a
solution very quickly.
Cheers /Carsten
------------------------------------------------------------------------
Carsten Germer Deutsches Elektronen Synchrotron (Web-Office, IT)
phone: +49-40-8998-1661 Notkestr. 85
web: http://wof.desy.de 22607 Hamburg
e-mail: carsten.germer@desy.de Germany
------------------------------------------------------------------------
>-----Original Message-----
>From: jslive@gmail.com [mailto:jslive@gmail.com] On Behalf Of
>Joshua Slive
>Sent: Friday, December 15, 2006 2:53 PM
>To: users@httpd.apache.org
>Subject: Re: [users@httpd] Mod re-write help
>
>
>On 12/15/06, Norman Khine <no...@khine.net> wrote:
>> Hello,
>>
>> I would like to know how to turn this URI
>>
>> http://destinationsguide.info/catalogue/c51/c57?b_start=15
>>
>> into something like
>>
>> http://destinationsguide.info/catalogue/africa/eastern-africa.html
>>
>> I am already using one rewrite into Zope, so I am not sure
>how to proceed.
>>
>> <VirtualHost *:80>
>> ServerName destinationsguide.info
>> ServerAlias www.destinationsguide.info
>> RewriteEngine On
>> #RewriteCond %{HTTP_HOST} ^www\.destinationsguide\.info [nc]
>> #RewriteRule (.*) http://destinationsguide.info [R=301,C]
>> RewriteRule ^/(.*)
>>
>http://destinationsguide.info:15080/VirtualHostBase/http/destin
ationsguide.info:80/destinations/VirtualHostRoot/$1
> [L,P]
The problem is a little under-specified. What do you mean by "turn
into"? Do you expect people to use the "pretty" url, and then you
will internally send them to Zope using the less-pretty one? Or do
you want to externally redirect between them so that people enter the
less-pretty url and then their browser location bar changes?
In addition, it is unclear how you expect the mapping between the two
urls to work in general. Do you have a list that maps one form to the
other?
Joshua.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server
Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org
Re: [users@httpd] Mod re-write help
Posted by Joshua Slive <jo...@slive.ca>.
On 12/15/06, Norman Khine <no...@khine.net> wrote:
> Hello,
>
> I would like to know how to turn this URI
>
> http://destinationsguide.info/catalogue/c51/c57?b_start=15
>
> into something like
>
> http://destinationsguide.info/catalogue/africa/eastern-africa.html
>
> I am already using one rewrite into Zope, so I am not sure how to proceed.
>
> <VirtualHost *:80>
> ServerName destinationsguide.info
> ServerAlias www.destinationsguide.info
> RewriteEngine On
> #RewriteCond %{HTTP_HOST} ^www\.destinationsguide\.info [nc]
> #RewriteRule (.*) http://destinationsguide.info [R=301,C]
> RewriteRule ^/(.*)
> http://destinationsguide.info:15080/VirtualHostBase/http/destinationsguide.info:80/destinations/VirtualHostRoot/$1
> [L,P]
The problem is a little under-specified. What do you mean by "turn
into"? Do you expect people to use the "pretty" url, and then you
will internally send them to Zope using the less-pretty one? Or do
you want to externally redirect between them so that people enter the
less-pretty url and then their browser location bar changes?
In addition, it is unclear how you expect the mapping between the two
urls to work in general. Do you have a list that maps one form to the
other?
Joshua.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org