tags:

views:

24

answers:

1

Hello All,

Guys i'm facing an issue regarding wordpress redirection.

I've used .htaccess on my website and i wish to make this work also for wordpress pages.I've installed wordpress in a folder named as "blogs" on the root like /blogs

I've also integrated/made changes in search.php of wordpress (domainname.com/blogs/wp-content/themes/my_theme/search.php) to my requirements. When someone searches the form action goes some thing like this: http://www.domainname.com/blogs/?s=keyword

This works fine but I want to use rewrite rule over this something like:

www.domainname.com/blogs/blog-keyword with http://

but it brings user to 404.php page of wordpress

my current htaccess file contains the following code under the blogs directory of root:

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

# Pads Landing / Searching Page
RewriteRule ^blogs/movie-(.*) /pads/?s=$1
</IfModule>

# END WordPress

Kindly help me I've few mins left for project deadline.

Thanks in advance.

A: 

Ok...

Check into Options -Multiviews

I've noticed issues when using wordpress

I use it like so

Options +FollowSymlinks
Options -Multiviews
RewriteEngine on

So

RewriteRule ^pads/movie-([^/]+)$ "http://%{HTTP_HOST}/pads/?s=$1" [R=301,L]

Hope it works. Lemeknow

Natrix
it doesn't work too
Kamran
I made some changes hope it works for ya.
Natrix
also if your rewriting the base directory to /pads/ then maybe you don't need the pads/ at the beginning of the rewrite. I would assume that it would be treating /pads/ as the new index directory. Not sure.
Natrix
Nops, this also fails to work for me...........Guys kindly take a look upon this issue and give me your best suggestions. Once again thank you for your contribution.
Kamran