forrest
forrest

Reputation: 10982

Expression Engine - template page not showing

I have two pages on a site that I just completed that are no longer showing. I am running EE 2.2.2 and use .htaccess to hide the index page.

There are several templates in the same directory, all but two of them show correctly. For example:

This shows correctly: http://southernlivingplants.com/landscape

While these two do not:

http://southernlivingplants.com/grower
http://southernlivingplants.com/retailer

I get the following error message:

Index of /retailer

Parent Directory

Apache/2.2.17 (Unix) mod_ssl/2.2.17 OpenSSL/0.9.8e-fips-rhel5 DAV/2 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635 Server at southernlivingplants.com Port 80

The problem I see is that neither /retailer or /grower are directories.

Here is the htaccess code:

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php?/$1 [L]

I would appreciate some help in figuring this out.

Upvotes: 0

Views: 2132

Answers (3)

forrest
forrest

Reputation: 10982

Alas, user error. Someone else had created folders of the same name, which were in conflict with the template names.

Upvotes: 2

Steph Rose
Steph Rose

Reputation: 2136

It looks like you are using the "File and Directory Check" method for the .htaccess file for ExpressionEngine.

Are retailer and grower template groups or templates in EE?

Have you tried removing the ? after the index.php in the rewrite rule? What hosting company are you using?

I have had best success with the "Exclude" method myself.

http://expressionengine.com/wiki/Remove_index.php_From_URLs#Exclude_List_Method

You essentially put in the ReWriteCond the folders / files that you do NOT want EE to parse as if it's a template. So, your /images, /system, /themes, etc directories, if you end up having one for /js or another application, you just add them to that line. (Make sure to escape the periods.) I suggest trying that method. That way everything else will definitely go through EE.

Upvotes: 0

FortySeven Media
FortySeven Media

Reputation: 48

If I put index.php in the URL the pages seem to come up, so it's probably an .htaccess issue. Have you been through the official docs for removing it? There's several options: http://expressionengine.com/user_guide/general/remove_index.php.html

Another idea...you said that retailer and grower are all in the same directory? EE doesn't generally work like that unless you're using Structure. Template groups define new top level directories and each template inside is a sub directory (other than the index). So in this case if they're all in the landscaping directory the urls' would be /landscaping/retailer and /landscaping/grower. Hope that helps!

Upvotes: 0

Related Questions