• Resolved ik80

    (@ik80)


    Independent on my permalink choice, WordPress always suggests the same htaccess configuration:

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /blog/
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /blog/index.php [L]
    </IfModule>
    
    # END WordPress

    I would like to have this permalink: /%year%/%monthnum%/%day%/%postname%/

    Didn’t this need a htaccess like???
    RewriteRule ^archives/([0-9]{4})?/?([0-9]{1,2})?/?([0-9]{1,2})?/?([_0-9a-z-]+)?/?([0-9]+)?/?$ /blog/index.php?year=$1&monthnum=$2&day=$3&name=$4&page=$5 [QSA]

    I’m running WP 2.3.1 on apache…

Viewing 6 replies - 1 through 6 (of 6 total)
  • No.
    Don’t touch the .htaccess.
    You set your permalink structure in your admin panel: Options > Permalinks.

    ik80,

    Hi. You would be correct if wordpress handled the rewriting through htaccess alone – I believe in earlier versions this was true. In recent versions, wordpress uses a class to handle url rewritting: WP_Rewrite

    The htaccess that wordpress generates is always the same because all it needs to do is send any request that is not an existing file or directory to your index.php file and WP_Rewrite will take care of everything.

    Thread Starter ik80

    (@ik80)

    thanks people, so way cant i use any decent permalink structure (without /index.php/ ?)
    gonna read this WP_Rewrite…

    Thread Starter ik80

    (@ik80)

    what are the specifications to get pretty permalinks working besides having mod_rewrite enabled (which is ok on my server)?

    mod_rewrite permalinks require Apache’s mod_rewrite module; people running WordPress on other server environments cannot use them. See Pretty Permalinks for more info.

    (source)

    Any permalink i try without /index.php/ (the almost pretty permalink) doesn’t work… HELP please!!!

    Moderator Samuel Wood (Otto)

    (@otto42)

    WordPress.org Admin

    To eliminate the index.php, you need:
    Apache
    mod_rewrite
    AllowOverrides enabled on the server (so that your .htaccess rules actually work)

    That’s it.

    Thread Starter ik80

    (@ik80)

    thanks Otto42. Gonna check this specs with the server admin…

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘WP suggests same htaccess for diff permalink types! Bug??’ is closed to new replies.