Source: site.view [edit]
Function name: a9storefront
Arguments: addr
Description: Produces an image of the storefront, given an address
Page type: webl
Render function:  
Module: global

Page source:

var res = nil;

var a = WubCall("parseAddress", [addr]);

var u = "http://amazon.com/gp/yp/sb/yp-search-dispatch.html?index=local&keywords=";

u = u + Url_Encode(a.address) + "&cityStateZip=" + 
        Url_Encode(a.city + "," + a.state + " " + a.zip);

var P = (GetURL(u) ? nil);
if P != nil then
   var T = Elem(P, "table") directlycontain Pat(P, `Business Name`);
   if Size(T) == 1 then
      var I = Elem(P, "img") inside T[0];
      res = (NewPiece(Markup(I[0]), "text/html") ? nil)
   end
end;

res;