[libvirt] [PATCH 2/2] docs: add advanced search capabilities

Daniel P. Berrangé berrange at redhat.com
Fri Apr 5 15:00:20 UTC 2019


On Fri, Apr 05, 2019 at 04:53:49PM +0200, Andrea Bolognani wrote:
> On Fri, 2019-04-05 at 14:30 +0100, Daniel P. Berrangé wrote:
> > Allow targetting the search scope to the website, wiki or mailing lists
> > only. When javascript is disabled this should gracefully fallback to
> > only searching the website.
> 
> I'm sure if the fallback doesn't work one of the many libvirt
> developers who configured their browsers to block JavaScript will
> complain swiftly and loudly :)
> 
> [...]
> > +#search:hover div.advancedsearch {
> > +    display: table;
> > +}
> > +
> > +
> 
> Extra line here.
> 
> [...]
> > +    for (var i = 0; i < whats.length; i++) {
> > +	if (whats[i].checked) {
> > +	    what = whats[i].value;
> > +	    break;
> > +	}
> > +    }
> 
> Alignment is out of whack here (and also in the pseudo-switch
> below).
> 
> [...]
> > +    } else if (what == "wiki") {
> > +	newq.value = "site:wiki.libvirt.org " + q.value;
> 
> MediaWiki has its own integrated search functionality, eg.
> 
>   https://wiki.libvirt.org/index.php?search=foo
> 
> Do you think we should still use Google for it?

Yeah, for consistency when we should use the mediawiki
search, since we've styled the two sites to look the
same for the navbar.
 
> > +    } else if (what == "lists") {
> > +	newq.value = "site:redhat.com inurl:/archives/libvir " + q.value;
> 
> This doesn't seem to work the way you'd expect.
> 
> When I search
> 
>   site:redhat.com
>   inurl:/archives/libvirt-users/
>   "macvtap and tagged VLANs to the VM"
> 
> I get a few hits[1], but if I change it to
> 
>   site:redhat.com
>   inurl:/archives/libvir
>   "macvtap and tagged VLANs to the VM"
> 
> then I get zero hits.

Odd that substring works for libvir-list, i guess they must give
the match because the index breaking "libvir-list" on the "-"

> If you don't feel like digging into why that's the case, I'm okay
> with either searching libvir-list only or having separate checkboxes
> for libvir-list and libvirt-users.

Separate checkboxes is easy enough.


Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|




More information about the libvir-list mailing list