![]() ![]() For my purposes, however, I often want to search the actual text of documents on Project Gutenberg. It has an “ advanced search” feature that allows people to craft narrower quick search queries. To see what the codes used in the “name” attribute, be sure to read through DuckDuckGo’s URL Parameters page.Project Gutenberg’s default “ quick search” (the search bar on its homepage) searches for books by title. I’ve included some of these parameters in the code below, which you can modify and use to add a custom DuckDuckGo search to your own site. ![]() Using a few of these parameters I was able to change the font to Helvetica, match the link colour on the search page to the links on Ben’s site, and turn off their sidebar. I got close, but wasn’t able to pass both the search term and limit the search to Ben’s site I could only do one or the other.Ī quick email to the support team at DuckDuckGo resulted in a small modification to my code to make it work, as well as an introduction to the other custom URL parameters available to customize the search experience even further. I started digging into the old code I’d made for the Google search form, to see if I could simply replace a few parameters to make it work on DuckDuckGo. While this provided the functionality Ben was looking for, it was a long way from the nice design I’d come up with for the former search bar. To make the switch to DuckDuckGo, Ben first replaced the custom Google search form with a search box he made using DuckDuckGo’s Search Box Wizard. With this form, I was able to style it using CSS to make it match the site’s design, as well as remove any Google branding. Previous to this change, I’d used a simple form that pointed to /search, with some additional parameters to limit the search to Ben’s site. ![]() In an effort to reduce the number of Google services he’s beholden to, Ben asked me to update his site’s search with the DuckDuckGo search service. My friend and colleague Ben Brooks is tired of Google, and I can’t blame him. Since writing this article, I’ve built a tool that makes it easy to design a customized DuckDuckGo search box for your website. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |