• I know this question has been asked countless times, but not until I started to mess around a little with this myself, did I discover that things to not go exactly as I hoped.

    I have tried a few plugins, some just don’t install, other need a page to display results other don’t seem to do what they promise. It can actually be quite simple. Here is a piece code that does the trick simply by editing the search.php. I am no coder, so I can’t get it to work the way I want. The displayed results look funky. The excerpt of the posts get the size of my metadata (really small). Also I would prefer if the search results could page. Last, but not least, an option to search sitewide or just the current blog would be nice as well.

    Can the above be accomplished with a little editing of the code of Lars or does anybody know of a plugin that does do what I’d like?

    [edit] Oh, a more serious problem with the code is that when you search for something that has no result in the site where you’re at, it doesn’t continue to search the other sites!

Viewing 2 replies - 1 through 2 (of 2 total)
  • That’ll only work on tiny sites as you’ve compiling all of the content from all of the blogs for each and every search at the time that search is made.

    I’d go one of two different routes.

    – Either install a sitewide indexer like either Donncha’s or the WPMuDev one. Both of those keep a running total of what’s on the site and it;s easier and quicker to do searches against that.

    – Get a Google Mini. (I actually host a 45k blog site that has one of these. Bright yellow. Looks weird against the other gray servers) ??

    The one that you reference is not the way to go. Old timers from back in the old pre 2.x WPMu days will remember ITDamage;s sitewide feed plugin and how slow that was. It took the latest 100 posts from each blog, compiled them and then skimmed the latest Posts to create a sitewide feed.

    You can cache the compiled Post data but if you;pre going to do that, you mind as well go with one of the other preexisting solutions. Be a waste of time just to redo everything.

    I will also point out that Lars just complains about the preexisting solutions. He doesn;t really say what the problem is. We use all three of the solutions I;ve suggested and all of them work on 3.0.x without issue.

    Someone else is going to have to give links though. I;m not feeling good tonight. No copy and paste I;m afraid.

    Thread Starter Roy

    (@gangleri)

    Ok, I see what you mean. I have but 5 subsites, so I’m not afraid to kill my database. I have tried some of plugins, like I said, but it is all not exactly what I want. The code I linked to comes closest to my needs with the few additions that I gave.
    I now use the default search widget (expanded with Search Everything) and a text widget with a Google search for the complete website (with an option to expand the search www). The latter could of course be expanded to make three options (current site, sitewide, www), but I would prefer the results within my own website (with sidebar, header, footer, etc.).
    In any case, the code with a few extras still sounds like an option, somebody who has tips for a better Google search are welcome too.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Sitewide search’ is closed to new replies.