• I have a wordpress site with url rewrite activated. I want to add two more url rewrites for my custom page

    RewriteRule ^page/([^/]*)$ page.php?$id=$1 [L]
    RewriteRule ^page/2/([^/]*)$ page2.php?$id=$1 [L]

    But when i add these lines, no use. It redirects to the wordpress page and saying no post found. How can i achieve this..

Viewing 2 replies - 1 through 2 (of 2 total)
  • Can you post your entire /.htaccess file so we can see the context in which you were using?

    Thread Starter gokul_8.9

    (@gokul_89)

    this is in my htaccess

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

    # END WordPress

    But if i add

    RewriteRule ^page/([^/]*)$ page.php?$id=$1 [L]
    RewriteRule ^page/2/([^/]*)$ page2.php?$id=$1 [L]

    to the top, no use. Please help me..

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Adding custom url rewrite to wordpress?’ is closed to new replies.