opensuse10.3/perfect server/ispconfig + .htaccess

Discussion in 'Installation/Configuration' started by Micha68, Dec 30, 2007.

  1. Micha68

    Micha68 New Member

    Hi!

    I had to install my root-server from scratch with OpenSuse10.3
    I use the perfect-Server-Setup and added ISPConfig.
    All works perfect except my .htaccess files. :confused:

    I use this .htaccess inside my picture-folder to output an error-picture, when a requested picture is not present:

    Code:
    <FilesMatch> 
      ErrorDocument 404 http://www.myserver.com/images/forum/fehler.gif 
    </FilesMatch>
    
    In my old Setup this works fine, with the new installation, not.
    Now, i cannot load ANY picture of that folder, i get always error 500.

    My phpinfo() shows at apache, rewrite is loaded.

    This is a part of my httpd.conf:

    Code:
    <Directory /srv/www/*/web>
        Options +FollowSymLinks +Includes -Indexes
        AllowOverride All
        #AllowOverride Indexes AuthConfig Limit FileInfo
        Order allow,deny
        Allow from all
        <Files ~ "^\.ht">
        Deny from all
        </Files>
    </Directory>
    
    Websites are stored in directory web.

    This is a part of my vhosts_ispconfig.conf:

    Code:
    <VirtualHost xxx.xxx.xxx.xxx:80>
    RewriteEngine On
    #RewriteOptions Inherit
    ServerName www.myserver.com:80
    ServerAdmin [email protected]
    DocumentRoot /srv/www/web2/web
    ServerAlias myserver.de
    DirectoryIndex index.html index.htm index.php index.php5 index.php4 index.php3 index.shtml index.cgi index.pl index.jsp Default.htm default.htm
    ErrorLog /srv/www/web2/log/error.log
    AddType application/x-httpd-php .php .php3 .php4 .php5
    <Files *.php>
        SetOutputFilter PHP
        SetInputFilter PHP
    </Files>
    <Files *.php3>
        SetOutputFilter PHP
        SetInputFilter PHP
    </Files>
    <Files *.php4>
        SetOutputFilter PHP
        SetInputFilter PHP
    </Files>
    <Files *.php5>
        SetOutputFilter PHP
        SetInputFilter PHP
    </Files>
    php_admin_flag safe_mode Off
    Alias /error/ "/srv/www/web2/web/error/"
    ErrorDocument 400 /error/invalidSyntax.html
    ErrorDocument 401 /error/authorizationRequired.html
    ErrorDocument 403 /error/forbidden.html
    ErrorDocument 404 /error/fileNotFound.html
    ErrorDocument 405 /error/methodNotAllowed.html
    ErrorDocument 500 /error/internalServerError.html
    ErrorDocument 503 /error/overloaded.html
    AliasMatch ^/~([^/]+)(/(.*))? /srv/www/web2/user/$1/web/$3
    AliasMatch ^/users/([^/]+)(/(.*))? /srv/www/web2/user/$1/web/$3
    </VirtualHost>
    
    I edited servername and ip here, in the original file, its the right adresses.

    Any idea!?

    Thanx,
    Michael


    SOLVED:
    My mistake, got en error in the htaccess-File.
    Just wondering, why the File worked in the old installation and now not.
    Old:
    <FilesMatch>
    ErrorDocument 404 http://www.myserver.com/images/forum/fehler.gif
    </FilesMatch>

    New:
    <FilesMatch ".(gif|jpg)">
    ErrorDocument 404 http://www.myserver.com/images/forum/fehler.gif
    </FilesMatch>

    First is wrong, i know, but why does it work before !?

    Michael
     
    Last edited: Dec 30, 2007
  2. falko

    falko Super Moderator ISPConfig Developer

    Maybe you had different Apache versions on both systems?
     

Share This Page