March 8th, 2010 | by Olivia | published in Youtube
All of the entries for Round 1 of Project: Report are in, and a panel of judges from the Pulitzer Center have chosen the top 10 semi-finalists. We saw terrific submissions from around the country, each telling a powerful story of an individual through …
March 8th, 2010 | by The Gmail Team | published in Gmail (Google Mail)
Posted by Emmanuel Pellereau, Software EngineerMy little sister recently setup her Gmail account to retrieve messages from her school address, so she can check all of her email accounts in one place. She no longer has to constantly log in to two email …
March 8th, 2010 | by Olivia | published in Youtube
On Sunday, despite as many as 100 bomb blasts throughout the country, according to news reports, Iraqi citizens flocked to the polls in higher-than-expected numbers to vote in the first nationwide parliamentary election since 2005. Amidst 38 confirmed …
Innovation wins for mid-sized business
March 8th, 2010 | by Ellen Petry Leanse | published in Google Apps, Google Enterprise
Editors’ note: Today’s guest blogger is David Rumberg, Partner and CIO of Sports Basement, a place where runners, swimmers, backpackers, fitness fans and triathletes can find great prices online on everything they need for their outdoor adventures. D…
And the searches go to…
March 8th, 2010 | by A Googler | published in Google Blog
The Oscars®: glitz, glamor, gossip, gold statuettes, much fanfare — and for many fans, Google search is increasingly a part of watching this live TV experience. Before and during the Academy Awards® broadcast in the U.S., we saw related queries on …
Spring Cleaning Only? Help Needed, Year Round.
March 8th, 2010 | by Google CPG Marketing | published in Google CPG
Posted by Vannie Shu, Account Planner, CPGSpring is finally here again. For many, the season ushers in Spring Cleaning, a time devoted to cleaning house from top to bottom.Many are going online in search of cleaning advice. Searches on the term “spri…
March 8th, 2010 | by Mike Marchak | published in Google Code
Google Summer of CodeTM, our flagship program to introduce college students to open source development, opens today. Over the past five years, we’ve seen more than 3,400 successful students “graduate” from the program, and we’re looking forward to welc…
March 8th, 2010 | by Jonathan Simon | published in Google Webmaster Central
Webmaster Level: AllLast October, we launched Webmaster Tools Labs and it has been a huge success. Malware Details have helped thousands of users identify pages on their site that may be infected with malicious code, and Fetch as Googlebot has given us…
March 8th, 2010 | by Leslie Hawthorn | published in Google Open Source
Looking for new contributors and fresh perspectives for your open source software project? Through the Google Summer of Code™ program, we fund students worldwide to work with mentors from the FLOSS community on a three month coding project. Over the …
March 8th, 2010 | by David Turner | published in Google Android
The third release of the Android Native Development Kit (NDK) is now available for download from the Android developer site.It can be used to target devices running Android 1.5 and higher. In addition to a few bug fixes and improvements, this release i…
March 8th, 2010 | by Jeffrey Posnick | published in Youtube API
There’s an upcoming change to YouTube video page URLs that we wanted developers to know about. While it’s not something that will directly affect users of the YouTube APIs, chances are there are some developers in the audience who have code that parses…
March 8th, 2010 | by A Googler | published in Google Blog
(Cross-posted from the Google.org Blog)What do tracking flu, helping consumers monitor their home electricity use, slowing deforestation and perhaps most importantly in 2010, helping the people of Haiti have in common?While they are all part of the wid…
March 8th, 2010 | by Jeff Scudder | published in Google Ajax API
One feature of the AJAX Image Search API that you might find useful is the ability to retrieve only the images which are visible on a specific website. For example, you could add a search box that allows people to search through just the images on your own site or you could create a slideshow which shows images from your favorite site.
To specify a site, use the setSiteRestriction
method on an ImageSearch
object. Here is a simple example:
http://code.google.com/apis/ajax/playground/#site_restrict
We can do more than just provide a site-specific image search box, we could also use the search results in a unique way. For example, we could create a slideshow which shows images which match our desired keyword and appear on a specific site. For this example, let’s create a simple slideshow that displays images from nasa.gov.
var imageIndex = 0;
var images;
function nextImage() {
imageIndex++;
if (imageIndex >= images.length) {
imageIndex = 0;
}
var imageContainer = document.getElementById(
'image-container');
imageContainer.src = images[imageIndex].tbUrl;
}
function searchComplete(searcher) {
if (searcher.results && searcher.results.length > 0) {
var contentDiv = document.getElementById(
'content-slideshow');
contentDiv.innerHTML = '';
var imageTag = document.createElement('img');
imageTag['id'] = 'image-container';
imageTag['src'] = searcher.results[imageIndex].tbUrl;
images = searcher.results;
contentDiv.appendChild(imageTag);
// Switch to the next image every 5 seconds.
setInterval("nextImage();", 5000);
}
}
function slideshowOnLoad() {
var imageSearch = new google.search.ImageSearch();
imageSearch.setSiteRestriction('nasa.gov');
imageSearch.setSearchCompleteCallback(
this, searchComplete, [imageSearch]);
imageSearch.execute('supernova');
}
google.setOnLoadCallback(slideshowOnLoad);
In the above samples, there are three lines I’d like to call your attention to. The first line to note is the imageSearch.execute
at the bottom, here we’ve entered the keywords that our slideshow images should be related to. Next we restrict the site to nasa.gov using imageSearch.setSiteRestriction
. Lastly, we call setInterval
once we receive the results of our search for images. The setInterval
call tells the browser to run our nextImage
function every five seconds.
Here are the two samples we’ve talked about in action:
The site restriction can also include a path within a website. For example you could do setSiteRestriction(
'http://www.flickr.com/photos/')
to search the photos that have been posted by a particular user on flickr.
To learn more about some other neat features of the AJAX Image Search API take a look at our code playground samples and documentation. For questions on this and other topics, drop us a line in the discussion group.
March 8th, 2010 | by Jeff Scudder | published in Google Ajax API
One feature of the AJAX Image Search API that you might find useful is the ability to retrieve only the images which are visible on a specific website. For example, you could add a search box that allows people to search through just the images on your own site or you could create a slideshow which shows images from your favorite site.
To specify a site, use the setSiteRestriction
method on an ImageSearch
object. Here is a simple example:
http://code.google.com/apis/ajax/playground/#site_restrict
We can do more than just provide a site-specific image search box, we could also use the search results in a unique way. For example, we could create a slideshow which shows images which match our desired keyword and appear on a specific site. For this example, let’s create a simple slideshow that displays images from nasa.gov.
var imageIndex = 0;
var images;
function nextImage() {
imageIndex++;
if (imageIndex >= images.length) {
imageIndex = 0;
}
var imageContainer = document.getElementById(
'image-container');
imageContainer.src = images[imageIndex].tbUrl;
}
function searchComplete(searcher) {
if (searcher.results && searcher.results.length > 0) {
var contentDiv = document.getElementById(
'content-slideshow');
contentDiv.innerHTML = '';
var imageTag = document.createElement('img');
imageTag['id'] = 'image-container';
imageTag['src'] = searcher.results[imageIndex].tbUrl;
images = searcher.results;
contentDiv.appendChild(imageTag);
// Switch to the next image every 5 seconds.
setInterval("nextImage();", 5000);
}
}
function slideshowOnLoad() {
var imageSearch = new google.search.ImageSearch();
imageSearch.setSiteRestriction('nasa.gov');
imageSearch.setSearchCompleteCallback(
this, searchComplete, [imageSearch]);
imageSearch.execute('supernova');
}
google.setOnLoadCallback(slideshowOnLoad);
In the above samples, there are three lines I’d like to call your attention to. The first line to note is the imageSearch.execute
at the bottom, here we’ve entered the keywords that our slideshow images should be related to. Next we restrict the site to nasa.gov using imageSearch.setSiteRestriction
. Lastly, we call setInterval
once we receive the results of our search for images. The setInterval
call tells the browser to run our nextImage
function every five seconds.
Here are the two samples we’ve talked about in action:
The site restriction can also include a path within a website. For example you could do setSiteRestriction(
'http://www.flickr.com/photos/')
to search the photos that have been posted by a particular user on flickr.
To learn more about some other neat features of the AJAX Image Search API take a look at our code playground samples and documentation. For questions on this and other topics, drop us a line in the discussion group.
March 8th, 2010 | by Mike Marchak | published in Google Code
This post is part of the Who’s @ Google I/O, a series of blog posts that gives a closer look at developers who’ll be speaking or demoing at Google I/O. This post is written by Albert Wenger, partner at Union Square Ventures (and still enjoys writi…