|
Home > Archive > WebSphere Commerce suite > November 2004 > Redirect domain to store
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Redirect domain to store
|
|
|
| Hello,
I am looking to redirect people from the root of the domain to a particalar
store using only Apache Redirect.
For example.
Currently I have instance hostname myinstance.mydomain.com
I would like people to be able to enter
store1.mydomain.com
and then redirect to
store1.mydomain.com/webapp/wcs/stores/servlet/CategoryDisplay?langId=-1&stor
eId=10001&catalogId=10001&top=Y&categoryId=10001
store2.mydomain.com
and then redirect to
store2.mydomain.com/webapp/wcs/stores/servlet/CategoryDisplay?langId=-1&stor
eId=10002&catalogId=10001&top=Y&categoryId=10001
Currently I have this working using Virtual Hosts, and an HTML redirect as
per these articles
http://www-1.ibm.com/support/docvie...s=utf-8&lang=en
http://www-1.ibm.com/support/docvie...s=utf-8&lang=en
I tried to also do it a redirect in my virtual host config in httpd.conf,
however this caused the browser to go in a loop.
Redirect 302 /
http://store1.mydomain.com/webapp/w...ategoryId=10001
I see there is a RedirectMatch directive as well, however wasn't able to get
a regular expression to work right.
Anyone have a solution to this they could share?
Thanks
Mark
| |
| Robert Brown 2004-10-27, 2:50 am |
| Under a single instance this is not possible. Remember the "blue" rule
for commerce -> one hostname, one database, one instance. You cannot
redirect traffic for hostname 1 (myinstance.mydomain.com) to hostname 2
(store1.mydomain.com) or hostname 3 (store2.mydomain.com). To achieve
this, you should create two instances, one for hostname 2 and one for
hostname 3. Each of these stores are a single instance of WebSphere
Commerce running under their respective hostname and have their own
database. Redirection rules from myinstance.mydomain.com (which is not
a WebSphere Commerce instance at all) can be passed to each of the two
instances per your client's business policies. Additional licensing may
be required to implement this solution...you might want to check with
you IBM sales rep.
You should probably consider the mod_rewrite module of the HTTP Server
to achieve the redirection you require if these rules are complex.
Hope this helps...
R
Mark wrote:
> Hello,
>
> I am looking to redirect people from the root of the domain to a particalar
> store using only Apache Redirect.
>
> For example.
>
> Currently I have instance hostname myinstance.mydomain.com
>
> I would like people to be able to enter
>
> store1.mydomain.com
>
> and then redirect to
> store1.mydomain.com/webapp/wcs/stores/servlet/CategoryDisplay?langId=-1&stor
> eId=10001&catalogId=10001&top=Y&categoryId=10001
>
> store2.mydomain.com
>
> and then redirect to
> store2.mydomain.com/webapp/wcs/stores/servlet/CategoryDisplay?langId=-1&stor
> eId=10002&catalogId=10001&top=Y&categoryId=10001
>
> Currently I have this working using Virtual Hosts, and an HTML redirect as
> per these articles
>
> http://www-1.ibm.com/support/docvie...s=utf-8&lang=en
> http://www-1.ibm.com/support/docvie...s=utf-8&lang=en
>
> I tried to also do it a redirect in my virtual host config in httpd.conf,
> however this caused the browser to go in a loop.
>
> Redirect 302 /
> http://store1.mydomain.com/webapp/w...ategoryId=10001
>
> I see there is a RedirectMatch directive as well, however wasn't able to get
> a regular expression to work right.
>
> Anyone have a solution to this they could share?
>
> Thanks
>
> Mark
>
>
>
>
>
>
>
>
| |
|
| Hi Robert,
Thanks for your reply.
I will check into mod_rewrite.
Mark
"Robert Brown" <rbrown@redbaritone.com> wrote in message
news:cln6vi$8jiu$1@news.boulder.ibm.com...
> Under a single instance this is not possible. Remember the "blue" rule
> for commerce -> one hostname, one database, one instance. You cannot
> redirect traffic for hostname 1 (myinstance.mydomain.com) to hostname 2
> (store1.mydomain.com) or hostname 3 (store2.mydomain.com). To achieve
> this, you should create two instances, one for hostname 2 and one for
> hostname 3. Each of these stores are a single instance of WebSphere
> Commerce running under their respective hostname and have their own
> database. Redirection rules from myinstance.mydomain.com (which is not
> a WebSphere Commerce instance at all) can be passed to each of the two
> instances per your client's business policies. Additional licensing may
> be required to implement this solution...you might want to check with
> you IBM sales rep.
>
> You should probably consider the mod_rewrite module of the HTTP Server
> to achieve the redirection you require if these rules are complex.
>
> Hope this helps...
>
> R
>
> Mark wrote:
>
particalar[vbcol=seagreen]
store1.mydomain.com/webapp/wcs/stores/servlet/CategoryDisplay?langId=-1&stor[vbcol=seagreen]
store2.mydomain.com/webapp/wcs/stores/servlet/CategoryDisplay?langId=-1&stor[vbcol=seagreen]
as[vbcol=seagreen]
http://www-1.ibm.com/support/docvie...s=utf-8&lang=en[vbcol=seagreen]
http://www-1.ibm.com/support/docvie...s=utf-8&lang=en[vbcol=seagreen]
httpd.conf,[vbcol=seagreen]
http://store1.mydomain.com/webapp/w...ategoryId=10001[vbcol=seagreen]
get[vbcol=seagreen]
>
|
|
|
|
|