在godaddy中找不到404错误页面?

时间:2014-10-18 10:34:43

标签: php apache .htaccess

我有一个名为'spotrecharge'的子域名。在这里我无法访问除索引页面之外的其他页面。我在所有其他页面上收到404错误。

enter image description here

我试图允许端口访问,但我无法让它工作。这是我的.htaccess文件中的代码。

SetEnv TZ Asia/kolkata

# Add the following header to every response
Header set Access-Control-Allow-Origin *
Header add X-HeaderName "Developed by"
Header add X-01 "iWebTechnik"

#Character Set
AddDefaultCharset utf-8
AddType 'text/html; charset=UTF-8' html

# year
<FilesMatch "\.(ico|pdf|flv|jpg|jpeg|png|gif|swf|mp3|mp4)$">
    Header set Cache-Control "public"
    Header set Expires "Thu, 24 Apr 2014 20:00:00 GMT"
    Header unset Last-Modified
</FilesMatch>

# 2 HOURS
<FilesMatch ".(html|htm)$">
    Header set Cache-Control "max-age=7200, must-revalidate"
</FilesMatch>

#2 DAYS
<FilesMatch ".(xml|txt)$">
    Header set Cache-Control "max-age=172800, public, must-revalidate"
</FilesMatch>

#2 HOURS
<FilesMatch ".(js|css)$">
    Header set Cache-Control "public"
    Header set Expires "Thu, 24 Apr 2014 20:00:00 GMT"
    Header unset Last-Modified
</FilesMatch>

# compress text, html, javascript, css, xml:
AddOutputFilterByType DEFLATE text/plain
AddOutputFilterByType DEFLATE text/html
AddOutputFilterByType DEFLATE text/xml
AddOutputFilterByType DEFLATE text/css
AddOutputFilterByType DEFLATE application/xml
AddOutputFilterByType DEFLATE application/xhtml+xml
AddOutputFilterByType DEFLATE application/rss+xml
AddOutputFilterByType DEFLATE application/javascript
AddOutputFilterByType DEFLATE application/x-javascript


<IfModule mod_gzip.c>
    mod_gzip_on       Yes
    mod_gzip_dechunk  Yes
    mod_gzip_item_include file      \.(html?|txt|css|js|php|pl)$
    mod_gzip_item_include handler   ^cgi-script$
    mod_gzip_item_include mime      ^text/.*
    mod_gzip_item_include mime      ^application/x-javascript.*
    mod_gzip_item_exclude mime      ^image/.*
    mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*
</IfModule>


<FilesMatch "\.(ico|jpg|jpeg|png|gif|js|css|swf)$">
    <IfModule mod_expires.c>
    ExpiresActive on
    ExpiresDefault "access plus 30 days"
    </IfModule>
    Header unset ETag
    FileETag None
</FilesMatch>


<files .htaccess>
    order allow,deny
    deny from all
</files>


Options +FollowSymLinks -MultiViews
RewriteEngine On
    RewriteCond %{SERVER_PORT} 80
    RewriteRule (.*)$ http://spotrecharge.iwebtechnik.com:80/$1 [R,L]
    RewriteRule \.(css|jpe?g|gif|png)$ - [L]

    RewriteCond %{REQUEST_URI} !^/folder/ [OR]
    RewriteCond %{REQUEST_URI} !^/folder/ [OR]
    RewriteCond %{REQUEST_URI} !^/s/ [OR]
    RewriteCond %{REQUEST_FILENAME} !-l [OR]
    RewriteCond %{REQUEST_FILENAME} !-f [OR]
    RewriteCond %{REQUEST_FILENAME} !-d
        RewriteRule ^/ - [S=4]
        RewriteRule ^a/([^/]+)/([^/]+)/([^/]+)/([^/]+)/?$ index.php?val1=$1&val2=$2&val3=$3&val4=$4 [NE,L,QSA]
        RewriteRule ^a/([^/]+)/([^/]+)/([^/]+)/?$ index.php?val1=$1&val2=$2&val3=$3 [NE,L,QSA]
        RewriteRule ^a/([^/]+)/([^/]+)/?$ index.php?val1=$1&val2=$2 [NE,L,QSA]
        RewriteRule ^a/([^/]+)/?$ index.php?val3=$1 [NE,L,QSA]

    RewriteCond %{REQUEST_URI} s/
        RewriteRule ^s/([^/]+)/?$ index.php?val3=$1 [NE,L,QSA]

感谢您的回复

0 个答案:

没有答案