Solved

How to configure zend ce for subdomain access?

Posted on 2012-03-20
8
297 Views
Last Modified: 2012-03-25
Dear sir,
How to configure zend server ce version(appache) to support web access via following manner:
"http://webmail.xxxx.com   ==  http://www.xxxx.com/webmail/
"
Please give me detail information on how to do this.

Thanks!
0
Comment
Question by:matiascx
  • 4
  • 4
8 Comments
 
LVL 51

Expert Comment

by:ahoffmann
ID: 37750316
in apache's configuration file use:

RewriteCond %{REQUEST_URI} !^/webmail/
RewriteRule ^$ /webmail/ [L]
0
 

Author Comment

by:matiascx
ID: 37750713
Sorry, I am a green hand, can you give me more explaination on how to do that and the meaning?

Thanks!
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 37751399
you need to find your apache's configuration file, it's usually named apache.conf or httpd.conf
check if the configuration loads the mod_rewrite module, if not add proper directives to load it
in that file you need to find the proper <directory> directive for the root directory
in that <directory scope you place:
  RewriteEngine On
  RewriteCond %{REQUEST_URI} !^/webmail/
  RewriteRule ^$ /webmail/ [L]

the meaning is that any request which is not /webmail/ (RewriteCond directive) will be rewritten to /webmail (RewriteRule directive)

i.g. this is not the place to explain completely how apache configuration works, there exist dozend of books and million of websites doing it ;-)
0
 

Author Comment

by:matiascx
ID: 37753033
For following description:

the meaning is that any request which is not /webmail/ (RewriteCond directive) will be rewritten to /webmail (RewriteRule directive)

It seems that it is not right? Maybe should be any request which is webmail.xx.xx will be rewritten to xx.xx/webmail

Is my understanding right?
0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 
LVL 51

Expert Comment

by:ahoffmann
ID: 37754916
> Maybe should be any request which is webmail.xx.xx
is this what your wish/expect, or what you mean what my rule does?
0
 

Author Comment

by:matiascx
ID: 37756373
Just because your explaination is not same with my expect or understanding.
I am not sure whether or not it is your mis-writing or my knowledge is error.
Can you clarify the rewrite rule in more detail explaination?
0
 
LVL 51

Accepted Solution

by:
ahoffmann earned 500 total points
ID: 37756687
# make a condition for the rewrite:
# check if the URL (which is in the variable %{REQUEST_URI) matches /webmail/ at the beginning (beginning: ^)
# if it does *not* match the condition is true

  RewriteCond %{REQUEST_URI} !^/webmail/

# now, if the condition above was true do the rewrite:
# rewrite an emtpy URL (beginning ^ immediately followed by the end $ ) to /webmail/
# if done, don not continue with rewriterules [L]



  RewriteRule ^$ /webmail/ [L]
0
 

Author Closing Comment

by:matiascx
ID: 37762844
Thanks!
0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

If your site has a few sections that need to be secure when data is transmitted between the server and local computer, such as a /order/ section for ordering or /customer/ which contains customer data, etc it would of course be recommended to secure…
This article discusses how to create an extensible mechanism for linked drop downs.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to count occurrences of each item in an array.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now