6 messages in com.googlegroups.google-base-data-apiRe: Google Base Image Link Issues (or...
FromSent OnAttachments
Ken G. aka. datamapper<at>gmail<dot>com15 Apr 2007 14:10 
Ken G. aka. datamapper<at>gmail<dot>com16 Apr 2007 11:08 
Robur MOW18 Apr 2007 13:48 
ShoreTel20 Apr 2007 17:40 
Jeff S23 Apr 2007 07:45 
Ken G. aka. datamapper<at>gmail<dot>com29 Apr 2007 19:20 
Subject:Re: Google Base Image Link Issues (or, When Is A Link Not A Link)
From:Ken G. aka. datamapper<at>gmail<dot>com (data@gmail.com)
Date:04/16/2007 11:08:35 AM
List:com.googlegroups.google-base-data-api

Ok Folks, Upon further investigation, my issue is because of Google's disallowance of "hot" linking to Base images, even if they are public, searchable, and on the "snippets" feed (in other words, my images/ links are not my images/links). My (ASP) solution:

Get the <g:image_link> url from the query results

Make the href (or img src) point to a "proxy" page on the server which will take the image url in the query string (e.g. <a href="getimage.asp?url=http:// base.google.com/base_image?q=hand-12345&size=1">Image Link</a>)

The proxy page gets the "url" parameter (and "size" parameter and concat's them), invokes a server-side XMLHttpRequest (MSXML2.ServerXMLHTTP.3.0), and uses it to GET the image and Response.BinaryWrite it back to the browser (Whew!)

See http://support.microsoft.com/kb/303982 for the MSXML2.ServerXMLHTTP ASP code. The web app is at www.ferrum.edu/blueridgenaturalist/

Hope this helps someone. Ken Gustafson

Hi All,

Trying to link to any of my (public/searchable) item's image in Base, but (almost) nothing I do is working. Got a map (with infoTabs) with a link to the item's image, but Google responds with a 404. Even forming a 'hard' link (<a href="link_to_image">) doesn't work, BUT typing in the exact same URL fetches the image!

Seewww.ferrum.edu/blueridgenaturalist/chestnutmapdebug.asp(use IE; working on Moz. functionality).

Click "Show Data", then click through alert/debug popups (sorry). Pulling data (shown in textarea at bottom) from Base account, which includes a <g:image_link> for each <entry>.

Click a flower icon, then the 'Full-size' link (or image placeholder). A 404 results (at least on my system). BUT, on that 404 page, manually change the "size" parameter (at the url's end) to "2" (for example; Base provides sizes ranging from 1(full-size)-6), a smaller picture comes up. NOW, change the "size" parameter BACK to "1" - THE DARN THING (FULL- SIZE) COMES UP! Also, when running the (basically same) code on my local machine everything works. Tried replacing "base.google.com" with "www.google.com" (which also works manually) but same 404 result.

There's a 'hard' link right above the textarea that points to one (piblic/searchable) item's image, but 404 also if clicked, but changing the "size" parameter as above gets the pic.

Any thoughts? Does Google look for a Key when accessing item images (doesn't seem so b/c manually typing in the image's url in a fresh window gets the pic). Does Base need "image/jpeg" Content-Type set? How may I further troubleshoot this?

Thanks for any input, Ken Gustafson