Redirecting specific category to subdomain

I have a problem in following situation:

I have 2 separate WordPress 3.3.1 instances, main at domain.com and one of them (which consists of simple Q&A type site) is available from subdomain forum.domain.com. Now I have to merge them into one instance – to be able to share plugins, theme and posts (<– that’s important).

Read More

At this moment, forum.domain.com points to that second instance. I can quite easily get rid of it just by creating post categories for questions and displaying them accordingly. But then, my questions will have links like domain.com/category/forum/question-subcategory/question and I want them to be like forum.domain.com/question-subcategory/question. I’ve seen that there is a WP Subdomains plug-in that does exactly that but it’s not compatible with WP 3.3.1. I thought that should be possible with .htaccess rules but this post seems to explain that it’s not.

I considered using WP Multi-site feature but as far as I know, separate sites have separate tables in DB, thus they can’t share posts (which is needed, as previously said).

Does anybody have any clue how to fix this problem ?

Related posts

Leave a Reply

2 comments

  1. Well, thanks for hints but finally, I had to abandon the idea of subdomain due to lack of working solution for this. I made separate categories for questions and used some hooks to display&operate on them properly. Thanks to the Custom Permalinks plugin, I now have domain.com (main blog) and domain.com/forum/ (Q&A), and the latter seems to be different site – with different headers, sidebars, logic, etc. from user’s point of view (it’s all on one instance, of course).

  2. I too struggled immensely trying to use subdomains for categories on my wordpress site. I tried a variety of plugins that were very buggy and eventually attempted writing my own. I kept running into additional problems left and right. Frequently I’d add new plugins that didn’t function properly with the unconventional subdomain setup and I ultimately gave up on trying to make this work.

    The only “solution” that I think might end up working is a wordpress multisite where each site holds posts for a given category then all sites are aggregated on a master site. This introduces another big heap of chores but I think it would actually function properly. It’d just be a pain in the neck.

    Anyway, to all that read this post, if you do find a solution that works for you, please do chime in and let us know.