All Low add-ons are now owned by EEHarbor. Read the blog post.

Support archive

Problems with Low Search and MSM

Joseph Wensley 9 Jan 2013 15:48 problem, pending

I'm building a site using MSM and I'm having some problems with Low Search on it.

We needed to be able to share blog posts between sites and specify which site each post would show up on so I have something like this set up.

Site 1
- Site Channels
Site 2
- Site Channels
Blog
- Blog
- Sites

The Sites channel contains an entry for each site and then the blog channel has a Playa field which is used to relate the post to whichever sites it needs to go on.

Now I'm trying to implement Low Search on Site 2 to search the blog posts that belong to Site 2 and I'm having some trouble with it.

My tags are like so

 
{exp:low_search:form
collection="blog"
query="{segment_3}"
result_page="search/results"
}
<input type="text" name="keywords" value="{low_search_keywords}" placeholder="Search">
<input type="submit" value="Search">
{/exp:low_search:form}


 
{exp:low_search:results
disable="categories|member_data"
limit="10"
query="{segment_3}"
site="blog"
child:sites="{site_2_entry_id}"
}
<!-- HTML -->
{/exp:low_search:results}


If I use this on Site 2 I end up getting all the blog entries, but if I run it on the Blog site I only get the entries related to Site 2.

Also, the docs say you can specify the site on the form tag, but I could only get it to work by putting it in the results tag.

Replies

  1. Low 9 Jan 2013 16:42

    I think this might be a bug: when looking up the field ID for the relationship fields, it will only look at fields belonging the current site, not taking any sites into account that were given in the site="" parameter.

    There's not really a quick fix, but I'll try and come with a solution as soon as I can.

  2. Low 11 Jan 2013 15:12

    Can you send me an email to hi at gotolow dot com, so I can send you a patched file? You can then try and see if that patched file solves the issue.