A picture is worth a thousand words. Adding the ability to search for images directly from your own website opens up the entire World Wide Web's collection of images to your viewers. Thanks to Google's comprehensive indexing of literally billions of images on the web and some simple decoding of URL parameters, you can create an image search tool on your website without needing to know complex scripting languages.
- Computer with Internet connection
- HTML editing program such as Notepad
- A live website with FTP access
Adding Google's Image Search to Your Website
Understand Google's Image Search URL. The important pieces that make up the URL you will use look like this: "http://images.google.com/images?q=searchterm." The part before the question mark references Google's Image Search address. Everything after it is the list of parameters that are used to define your particular search. The primary parameter is the "q=" parameter, which stands for "query". This is the part that includes your search terms. Additional parameters are noted below under the Advanced Parameters section.
Create a form that will pass inputted text from a text box on your site to the query parameter and submit it to Google's Image Search. You can paste the following code directly into your HTML file where you want the image search box to show up (see the References for an example of this on askdavetaylor.com):
<form method="get" action="http://images.google.com/images" target="_blank">
<input type="text" name="q" />
<input type="submit" value="Search Google Images" />
Save and publish your HTML file, then test it out.
Control the search results by defining additional parameters. Additional parameters include the following: "as_eq," "imgtype," "imgsz," "imgw," "imgh," "imgar," "as_filetype," "imgc," "as_sitesearch," "as_rights," "safe," and "as_st." Refer to http://images.google.com/advanced_image_search for the visual interface for all of these parameters.
Make the selections you want on the visual interface link, then press "Google Search" to set an advanced parameter. Copy the URL that is returned.
Find the parameters that match your settings; for example, if you limited the "Domain" to "ehow.com," then you would want a parameter that says, "as_sitesearch=ehow.com."
Create a hidden input field in your form for each advanced parameter you want to include. Do so in the following manner: <input type="hidden" name="as_sitesearch" value="ehow.com">, where "name" is equal to the parameter you want to include and "value" is equal to the value of that parameter.
Save and publish your HTML page and test.
- Photo Credit search and magnifier buttons. (with clipping path) image by Andrey Zyk from Fotolia.com
How to Add Flickr Images to a Web Page
Comments. You May Also Like. How to Create a Feed When You Do an Image Search on Flickr. Flickr is an online...
Top Internet Image Search Engines
Top Internet Image Search Engines. One of the Internet's most popular features is the ability to search for images related to almost...
How to Make a Twitter Background Image
Twitter has become such a popular social network website and you will want to personalize your twitter background wallpaper image. The problem...
How to Search for Images
Select the image you want by clicking on it. This will load the website it is displayed on. You can alter the...
How to Create a Search Button for My Website
Creating a search button on your website is very easy. Major Internet search engine companies allow you to insert code on your...
How to Make and Then Enlarge Thumbnail Images on a Website
The Internet is a fast place. Typically most users will not wait more than 10 or 15 seconds for a page to...
How to Create a Vector Image in Photoshop
When people think about creating vector graphics, they tend to think of CorelDraw or Abode Illustrator. But while it is true that...
How to Make My Safe Search Preferences Stick
Google safe search is preference used by browsers that filter out adult material. It can be used by parents as a means...
How to Make Word Search Puzzles for Free
A word-search puzzle is a two-dimensional box filled with letters in which you find hidden words that you circle. You can create...
How to Create an Advanced Search Box
To make finding information easy, many websites include search boxes on their main page. Visitors can type a search term into the...
How to Build a Travel Search Engine Website
A website with a travel search engine allows users to search for the best deals on vacation packages, hotels, resorts, plane and...
How to Create an Image Map in Illustrator
Adobe Illustrator is a widely available graphics-editing software suite that is compatible with both Windows and Mac OS. Creating an image map...
How do I Create a Fish Image on a Birthday Cake?
Fish birthday cakes are appropriate both at children's birthday parties with an underwater or fish theme and at adult birthday parties for...
How to Get an Image URL
In the age of the digital camera, it's only natural to want to share your photos with as many people as you...
How to Make a Google-friendly Website
When making a website, the main search engine that you want to impress is the largest and most popular search engine. That...