Hello, i installed a drupal 7 website and i want to use wordpress and my drupal site together. i created a drupal 7 application and wordpress application, then i linked my drupal 7 app to my root directory "/" and wordpress app to "/blog" paths. On my drupal 7 website in my main navigation i have a blog link, which is linked to mysite.com/?q=blog url, but i cannot redirect it to mysite.com/blog url, when i directly enter mysite.com/blog url to my browser i can reach my wordpress site, it seems simpe but i cannot redirect ?q=blog url to just "blog " path... thanks in advance asked 07 Oct '11, 04:31 realbezo |
Hi, You can't match the GET parameter "q" inside the Rewrite rule. You need to use the RewriteCond directive for this. Here are the Rewrite rules you need to use in order to do such a redirection:
If you still have troubles using these rules, please open a support ticket, and we will look at your .htaccess. answered 07 Oct '11, 05:31 todork thank you, it worked, i can open now my wordpress site by the way the rule redirects me not http://www.mysite.com/blog/ url instead it redirects me to http://www.mysite.com/blog/?q=blog url but it still works, and opens my main wordpress page p.s. i think i have really little knowledge about rewrite rules and htaccess file, thank you for patience and help
(07 Oct '11, 06:34)
realbezo
You are most welcome! Yes, unfortunately the GET parameter gets passed to the new URL as well - I'm not aware of a way to bypass this.
(07 Oct '11, 06:38)
todork
|
Hi,
Can you provide some more information on how you are doing the redirection? Do you use Rewrite rules in .htaccess? Please paste them here if so.
RewriteRule ^?q=blog$ http://www.myysite.com/blog [R=301,L] i tried this but nothing changes
and when i try RewriteRule ^?q=blog$ http://mysite.com/blog [R=301,L]
i get
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.