As far as I can see, this is kind of a bug for the standard category taxonomy. In fact, if you try that syntax with any other taxonomy, it works. So, a workaround could be to convert the standard category taxonomy into a custom taxonomy and make it behalf as a category with 'hierarchical' => true
. Then you will be able to use something like:
?custom-taxonomy=slug1+slug2.
Not very elegant, but it could be a solution for you.
EDIT:
As WordPress evolved, we can say that the standard Category and Tags became special cases of the Taxonomy concept. Each of them is a default Taxonomy for posts. Since version 2.3 WordPress introduced custom taxonomies. With custom taxonomies, you can create any kind of special taxonomy, with some possible customization, that make them behalf more like a tag or more like a category. That said, they all work with the same syntax, let's say:
yoursite.com/?taxonomy-name=taxonomy-item
That url will list all the posts categorized as taxonomy-item
. For some reason (a bug, I guess), the standard ?cat=1+2 does not work as it should, but every other taxonomy does, indeed. To be clear, you could replace
yoursite.com/?cat=dogs+cats
with
yoursite.com/?pets=dogs+cats
by creating a custom taxonomy named 'pets'. And that will do the job.
If you create a custom taxonomy, and use it as a replacement to you standard category, you would be able to make this work with no further development. If you are unfamiliar with custom taxonomies, try the Custom Post Type UI plugin, that will do the dirty work for you. The most important setting in order to have a custom taxonomy that behaves as the default categories is to set it as hierarchical.
Let's say you create a custom taxonomy called "new-cats". After that, you will be able to use yoursite.com/?my-cats=cat1+cat2 and that will list post categorized with cat1 AND cat2. By the way, this could give some SEO benefits out of the box. Of course, you will need to categorize all of your posts with the new taxonomy. Something like this could help http://themespotter.com/how-to-convert-post-tags-to-custom-taxonomies-in-wordpress/