1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Problems with ticketing system caused by .htaccess file

Discussion in 'Content Management' started by Sunlust, Aug 13, 2008.

  1. #1
    Hi,

    We have an online ticketing system that always worked fine, but after Joomla's installation, because of the .htaccess file it doesn't.

    The default for us:
    RewriteEngine On
    
    RewriteCond %{HTTP_HOST} !^$
    RewriteCond %{HTTP_HOST} !^www\.smesolutions\.co.uk$ [NC]
    RewriteRule !^blog(/.*)?$ http://www.smesolutions.co.uk%{REQUEST_URI} [R=301,L]
    
    Code (markup):
    Thanks to that .htaccess our website works and it has SEF on, but the ticketing system doesn't, because our subdomain got redirected to the main domain.

    So I rewrote it to:
    
    RewriteEngine on
    RewriteBase /
    RewriteCond %{HTTP_HOST} ^www\support.smesolutions\.co.uk
    RewriteRule ^$ ticket/ [R=301,L]
    
    Code (markup):
    With this the website works and SEF is on but when I go to the ticketing system at support.smesolutions.co.uk I can't see the wording in the software, only the code.

    So I deleted the .htaccess file and the ticketing system works fine, but the website doesn't, I get 404's all around the place.

    Problem is that I need to keep the current url structure for my website, it's quite big and many things are based on static links I've setup based on the urls created by mod_rewrite.

    Does anyone have any idea how to solve this issue?
     
    Sunlust, Aug 13, 2008 IP
  2. blackonyx

    blackonyx Peon

    Messages:
    223
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    0
    #2
    I am not even sure, I understand your problem correctly. So you have the main website with a CMS on www.smesolutions.co.uk and a ticketing system on www.support.smesolutions.co.uk, right? Sounds to me like using two virtual host containers would elegantly keep those two apart.
     
    blackonyx, Aug 13, 2008 IP
  3. Sunlust

    Sunlust Active Member

    Messages:
    448
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    60
    #3
    Heh, yeah that's the problem :D, I fixed it by making a redirect from support to other domain and setup new ticket system there instead, I don't know what virtual host containters are :/ Maybe one day I'll learn.
     
    Sunlust, Aug 14, 2008 IP
  4. blackonyx

    blackonyx Peon

    Messages:
    223
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    0
    #4
    A virtual host container simply is <virtualhost></virtualhost> in your apache config. As far as I understood it, you have something like:

    <virtualhost>
    Servername: www.smesolutions.co.uk
    Serveralias: support.smesolutions.co.ok
    Documentroot: /var/www/htdocs
    </virtualhost>

    Simply put two of those virtualhost sections in your apache config and your htaccess files wont interfere any longer. Even better: You can skip htaccess files altogether and include their directives directly in the apache config, which is the recommended way to do it anyway.
     
    blackonyx, Aug 14, 2008 IP