We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

500 Internal Server error with Generate .htaccess extension

Development and Programming

Mikee Bee's avatar
Mikee Bee
179 posts
16 years ago
Mikee Bee's avatar Mikee Bee

Hi all, I am using the Generate .htaccess extension and I keep getting a 500 Internal Server error when I try and use it on Site5 servers.

I developed the site locally and it worked fine.

The Site5 support team sent me this as the exact error in the error log..

[Wed Dec 17 11:09:26 2008] [alert] [client 93.86.146.123] /home/myragonz/public_html/.htaccess: RewriteCond: cannot compile regular expression '^/(includes|about|talent|aboutmyra|artists|contact|fashion4film|home||members|P[0-9]{2,8})'\n

Can anyone see why this is happening? I really don’t understand!

Thanks

Mike

       
Leevi Graham's avatar
Leevi Graham
1,143 posts
16 years ago
Leevi Graham's avatar Leevi Graham

You have a double pipe || in your generated file which is causing the issue. If you’re not using E pages remove the {ee:pages} variable.

       
birdie's avatar
birdie
68 posts
16 years ago
birdie's avatar birdie

Hi, I am having a similar issue with the 500 Error. I have checked through and can’t find a double-pipe anywhere, and have removed pages from the settings. Any ideas? This is a completely fresh install so only the ‘site/index.php’ template exists so far.

Thanks,

Cormac

# -- LG .htaccess Generator Start --

# .htaccess generated by LG .htaccess Generator v1.0.0
# http://leevigraham.com/cms-customisation/expressionengine/addon/lg-htaccess-generator/

# secure .htaccess file
<Files .htaccess>
 order allow,deny
 deny from all
</Files>

# Dont list files in index pages
IndexIgnore *

# EE 404 page for missing pages
ErrorDocument 404 /index.php?/

# Simple 404 for missing files
<FilesMatch "(\.jpe?g|gif|png|bmp)$">
  ErrorDocument 404 "File Not Found"
</FilesMatch>

RewriteEngine On

RewriteBase /

# remove the www
RewriteCond %{HTTP_HOST} ^(www\.$) [NC]
RewriteRule ^ http://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

# Add a trailing slash to paths without an extension
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_URI} !(\.[a-zA-Z0-9]{1,5}|/)$
RewriteRule ^(.*)$ $1/ [L,R=301]

# Remove index.php
# Uses the "include method"
# http://expressionengine.com/wiki/Remove_index.php_From_URLs/#Include_List_Method
RewriteCond %{REQUEST_URI} !(\.[a-zA-Z0-9]{1,5})$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_URI} ^/(site|members|P[0-9]{2,8}) [NC]
RewriteRule ^(.*)$ /index.php?/$1 [L]

# Remove IE image toolbar
<FilesMatch "\.(html|htm|php)$">
  Header set imagetoolbar "no"
</FilesMatch>

# -- LG .htaccess Generator End --
       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.