ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Upgrade 2.0.2 to 2.5.2 htaccess issue

August 13, 2012 5:02pm

Subscribe [1]
  • #1 / Aug 13, 2012 5:02pm

    bytte

    47 posts

    I’ve upgrade my EE site from version 2.0.2 to 2.5.2 and all went well except I’m having an issue with my url structure.

    In version 2.0.2 this line in my htaccess file worked fine:

    RewriteRule ^(en|fr|nl|es)/(.*)$ $2/$1

    I used it so i could use url’s like

    <a href="http://www.site.com/en/template_group">http://www.site.com/en/template_group</a> instead of <a href="http://www.site.com/template_group/en">http://www.site.com/template_group/en</a>

    The RewriteRule changed the order of language selector and template group so EE could find the correct template. But since the upgrade to 2.5.2. this isn’t working anymore.  If i use {segment_1} it still gives me the language and not the template.

    For completeness these are the other lines in .htaccess:

    RewriteRule ^(en|fr|nl|es)/(.*)$ $2/$1
    RewriteCond $1 !\.(gif|jpe?g|png)$ [NC]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ index.php/$1 [L]

    Any idea?

  • #2 / Aug 14, 2012 5:24pm

    Kevin Smith

    4784 posts

    Hi bytte,

    This isn’t something we can help with, but I’d be glad to move this thread over to Community Help to see if anyone can offer up a suggestion for you there. Would you like me to do that?

  • #3 / Aug 14, 2012 10:50pm

    bytte

    47 posts

    Are you sure there wasn’t an update to EE since 2.0.2 in the way it interpretes the url structure? Weird this worked great but stopped working after the upgrade.

  • #4 / Aug 16, 2012 11:49am

    Kevin Smith

    4784 posts

    A lot has changed since EE 2.0.2, but I don’t believe the way EE interprets URL structure has changed. If you take the rewrite rule out of the picture and just try to access the URLs as they really exist according to EE, does it work?

  • #5 / Aug 16, 2012 3:21pm

    bytte

    47 posts

    Yes, that still works as intended.

  • #6 / Aug 17, 2012 1:07pm

    Kevin Smith

    4784 posts

    Ok, so with that in mind, there’s something askew with your .htaccess rules. I’d recommend working with your web host to troubleshoot what’s going on there. I can also move this over to Community Help if you’d like!

  • #7 / Sep 12, 2012 5:54am

    bytte

    47 posts

    Thanks Kevin, would be great if you could move it over.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases