I using EE 2.10 for a test site.

Is there any tag I can use to make this navigation work for all my pages other than placing the direct url in the href HTML tag? I tried using the "url_title_path" but it gives me a page not found. Also, if you look at the home page URL "http://www.mannachurch.org/ExpressionEngine/index.php" this site is being shared on a server under another domain. So, I guess this site is a sub-domain? Do I need to redirect the .htaccess file to remove any unnecessary "index.php" for the URL tags to work? Or can I use anything else? I am afraid of messing up my primary domain's website by uploading any new .htaccess files.

To be clear, below is what my code looks like for my navigation that I am trying to configure. The first two links for 'Home' and 'about' are direct links, this is what I want to avoid. The next three links ('News', 'Apply', 'Contact') are an attempt on my behalf that do not work apparently. How can I make those work? enter image description here

Whenever I click on my failing url links links, I get a page cannot be found error and that's also the main domain's site no page found page, why is it going there? Please observe yourself.

1 Answer 1


Firstly - the links. Assuming that {url_title_path='pages/contact'} etc is working at rending out the URL, albeit with index.php in it, then the only issue is your index.php and removing it. Although note that it's best to always use relative URLs, and personally I've never understood the point of using the url_title_path tag when you have to specify the path anyway - simply coding /pages/contact into your template is 18 characters less to type, less template parsing to do and just as 'hard coded' and flexible as specifying the template group/template!

Secondly the index.php rewrite.

On your main root website (http://www.mannachurch.org/), it already has an .htaccess in the root which rewrites the index.php so assume it's another EE build. Because you can access the ExpressionEngine folder, it's already been excluded in the .htaccess file, so no need to modify it. So you need to create a new .htaccess file in the ExpressionEngine folder that does the index.php rewriting. Best bet might be to copy the existing root .htaccess and modify it to include the sub folder. Something like:

<IfModule mod_rewrite.c>
        RewriteEngine On
        RewriteBase /

        # Removes index.php from ExpressionEngine URLs
        RewriteCond %{THE_REQUEST} ^GET.*index\.php [NC]
        RewriteCond %{REQUEST_URI} !/system/.* [NC]
        RewriteRule (.*?)index\.php/*(.*) /$1$2 [R=301,NE,L]

        # Directs all EE web requests through the site index file
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteRule ^(.*)$ /ExpressionEngine/index.php/$1 [L]

Should do it - modify the folder names to match . The official instructions are here.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.