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.

Trouble in SAEF, Safecracker and Comment by redirecting .htaccess

August 18, 2012 3:16am

Subscribe [2]
  • #1 / Aug 18, 2012 3:16am

    4ksner

    12 posts

    Hi All!
    Now, I`m trying update EE from 1.6.9 to 2.4 version.
    SAEF and Safecracker stopped working on EE 2.4.
    In my .htaccess file there is code:

    RewriteCond %{REQUEST_FILENAME} !-f 
    RewriteCond %{REQUEST_URI} !\..{1,10}$ 
    RewriteCond %{REQUEST_URI} !(.*)/$ 
    RewriteRule ^(.*)$ <a href="http://www.mysite.ru/$1/">http://www.mysite.ru/$1/</a> [L,R=301]

    When I delete this code - SAEF and Safecracker begin working.

    I`m need this redirect, because it glues pages with “/” and without “/”.

  • #2 / Aug 20, 2012 1:07pm

    Shane Eckert

    7174 posts

    Hello 4ksner,

    I am sorry to hear you are running into this problem.

    We do not support any htaccess configurations aside from the one below.

    I can move this over to the Community Help Forum if you would like.

    <IfModule mod_rewrite.c>
            RewriteEngine On
    
            # Removes index.php
            RewriteCond $1 !\.(gif|jpe?g|png)$ [NC]
            RewriteCond %{REQUEST_FILENAME} !-f
            RewriteCond %{REQUEST_FILENAME} !-d
            RewriteRule ^(.*)$ /index.php/$1 [L]
    
            # If 404s, "No Input File" or every URL returns the same thing
            # make it /index.php?/$1 above (add the question mark)
    </IfModule>

    If there is anything else I can help with, please let me know.

    Cheers,

  • #3 / Aug 22, 2012 7:32am

    4ksner

    12 posts

    It is a pity that you can not help me.
    Please move this topic to the Community Help Forum.

  • #4 / Sep 16, 2012 3:26am

    4ksner

    12 posts

    Temporarily solved the problem by changing the redirect is:

    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_URI} !^\/add-(.*)$
    RewriteRule ^([^.]+)(?<!/)$ /$1/ [R=301,L]

    In this redirect, I added an exception - a page with the prefix “add-”, because they contain the code Safecracker.
    I was already happy when it worked, but then I noticed that the comments are not working.
    Again, because of the redirect.

    I have no idea what to do.

     

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

ExpressionEngine News!

#eecms, #events, #releases