Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

LiveSearch 1.1

24

Comments

  • Hi a_j, the fix was more for general concern. About your problem... Do you have any extensions that add <body onload="..." stuff?
  • jazzman it cant be extensions as it doesnt work on your forum for me either. However it does work on my localhost.
  • edited July 2006
    Thanks Jazzman, this is very nice. Is there any way it could strip out the BBCode when displaying comments? (if the admin has it enabled) That's probably too much work, but I just wanted to bring it up as a suggestion.
  • @Jazzman, I probably do (I have many), but the problem persists even if I disable all of the other extensions besides LSearch. It is really strange how it is pulling down the header and tabs into the live preview. It's almost as if css classes are crossing or something. But why would it happen in the discussion and not on the discussions main page?
  • It would be cool if, instead of making you choose what kind of search you wanted, it would just do all three searches, and return the first five users, the first five topics, and the first five comments, spotlight-style.
  • Bergamot, I like your thinking. That sounds ideal.
  • edited July 2006
    Yeah, Bergamot, smoothe! How about to the right of the results category heading putting a "more" link to expand the search beyond the top 5 in any category.
  • edited July 2006
    Ok, I made the necessary modifications, which you can play with on my test board here.

    image
  • That really is perfect.I hope Jazzman implements something like that in the official release. Its just alot more intuitive. I don't think users would think "Oh, I'm on a comments page so it'll search comments", or "I'm on a user page, so it'll search users".
  • Is that update part of the extension now or is that version of the Add-On not available for download right now? Looks awesome, can't wait to install it.
  • No it isn't, but I'd be glad to give Jazzman the code if he wants it (the changes were really minor; just put the ajax code in a big loop, and make some stylesheet changes)
  • edited July 2006
    Perhaps it would be a bit more intuitive if instead of displaying the results inline, it would be in a dropdown box - like I have in the live search on my site? I mean, to have text and divs being pushed around by the results is a bit clumsy. Having a dropdown or hovering div would be a little more page-friendly.
  • That would be really easy to do, but I'm not sure I like it covering up other content.
  • True. I'm with you on that.
    But what if the damage was made minimal by combining both ideas? Have a hovering div that acted like a dropdown - but only over the sidebar. And making it act like a dropdown would mean people could hit (esc) or just exit the dropdown to reveal the normal page content.

    That way the main part of the page is left intact and you can limit the dropdown to the sidebar. Just a thought? Or is that the content you don't want covered up?
  • Well there's useful stuff on the sidebar too, and honestly I'd rather just bump it down than cover it up. Maybe push it away with a fancy animation or something if it's too jarring.

    It also annoys me when javascript popups don't disappear on click-out, but instead make you click a "close" link.
  • Well - by acting like a normal dropdown it would have to have the function of exiting with clickout - just like a real dropdown.

    You mean have the search slide down the panel text down slowly? See, the only problem I foresee is large search results causing people to have to scroll down to get to the same content you don't want to cover up. Or maybe have it slide out of the side over the discussion board so its not blocking the sidebar, and its only blocking a few comments.
  • this is a great extension.
  • hey bergamot, could you post your mods?
  • edited July 2006
    Sure.

    ajax.php becomes:
    --source code removed--

    That's 99% of the hard work, and as you can see I only changed maybe 6 lines of code.

    For completeness' sake, open default.php and change the getLiveSearchType function to:
    --source code removed--

    and use this as style.css
  • Well. That didn't work. Any chance you could send me the bundled files? It totally screwed my forum. An error on every page and I could not view a thing.
This discussion has been closed.