page nit correctly redirected

Discussion in 'Installation/Configuration' started by kmchen, Jan 16, 2012.

  1. kmchen

    kmchen New Member

    Hi
    I try to define a subdomain thqt should come to a Joomla CMS.
    I defined an A record subdomain on the domain and then tried all sorts of redirections in the ispConfig3's domain website.
    In the doc it's said in case of CMS you must define a complete new website but how do one create the redirection from the subdomain to the new website at bind and apache level in ispconfig ?
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Normally you dont need a redirect at all as joomla handles this internally.

    1) Create a ndw dns A-Record or cname record.
    2) Add the subdomain as subdomain or aliasdomain to the website where it shall point to. Apache then redirects all requests automatically to that site.

    If you want that the URL in the browser changes to the main site as well, then add a redirect to the URL of the main site in the redirect field. The uRL start with http://

    Be aware that changes in dns take 24-48 hours, so dont expect that you A-Record works right after you added it.
     
  3. kmchen

    kmchen New Member

    Thanks for your reply.

    The main domain AND subdomain rely to complete different joomla CMS constructs.
    In ispConfig3 subdomains I put:
    host:test
    domain: mainDomain.tld

    I don't want name (test.mainDomain.tld) change in browser but if I put "redirect type: no redirect" I get to the main site. So I put "redirect type: no flag".

    Then, if I put "redirect path: /var/www/fictive-domain-locally-created.tld/web/" I get "You don't have permission to access / on this server"

    If i put "redirect path: /test/" it's OK with a static /var/www/mainDomain.tld/web/test/index.html but if I put a CMS instead index.html, I get "The server encountered an internal error or misconfiguration and was unable to complete your request."
    (I think url .htacess rewrites conflict.)

    So. How to simply build my test.mainDomain.tld ?

    PS: pubs overlap parts of posts so it's unreadable
     
    Last edited: Jan 17, 2012
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    You have to create a website in ISPConfig and not a aliasdomain then as described in the manual. The reason for that is quite simple, Joomla uses its own redirect rules, so if you use a apache redirect to forward requests to directory test and then install a joomla there which does another redirect, then apache will fail.

    A website in ISPConfig is the equivalent to a vhost in apache and each joomla install requires its own vhost to do its rewriting properly. So you just have to add your subdomain as website and not as aliasdomain if you want to install a cms system like joomla / wordpress / Drupal or Typo3 in it.
     
    Last edited: Jan 17, 2012
  5. kmchen

    kmchen New Member

    Wow! Are you meaning that one can't have a Joomla on a domain.tld and an other Joomla on sub.domain.tld !
    :(
     
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    Thats not what i said. You can have as many joomla installs on subdomains as you like. You might want to reread my post and follow the steps that i explained there to create a subdomain website for joomla. You find the same instructions in the manual btw, so just follow them and yoz get a working subdomain website for joomla.
     
  7. kmchen

    kmchen New Member

    Well. Excuse my missunderstandings.

    So I make an ispconfig website main_domain.tld and then another let's say fictive_name.tld.
    Each has a joomla in it's web directory. I can access fictive_name.tld, via local /etc/hosts manipulations.

    I create a subdomain like that:
    Code:
    Host: subdomain
    Domain: main_domain.tld
    Redirect Type: no flag
    Redirect Path: http://fictive_name.tld
    But when I browse to subdomain.main_domain.tld I get "403 Forbidden"
     
    Last edited: Jan 18, 2012
  8. till

    till Super Moderator Staff Member ISPConfig Developer

    No, what I meant is different:

    1) Delete fictive_name.tld and the subdomain.
    2) Then click On: Sites > Websites > Add new website. In the website form enter as domain:

    Domain: subdomain.main_domain.tld

    and click on save. Now you have a new website (vhost) for subdomain.main_domain.tld where you can install your second joomla installation to.
     
  9. kmchen

    kmchen New Member

    Yes! It works this way !

    Thanks for your patience
     

Share This Page