Zestimate API in iFrame help

Profile picture for darryll
I am trying to have the zestimate be on my page in a frame, but dont know how to implement it, is there tutorials anywhere?  Thanks.
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 18 2009 - US

Replies (23)

Iframes are actually pretty easy. Try doing a google search for 'how to use iframe' or 'iframe html code'. You can usually copy and paste examples with minor modification. If you search around you can usually find ones that control the size of the iframe using java.
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 18 2009
Profile picture for darryll
Yeah I know how to use iFrames, sorry guess I was not clear.  I dont understand how the API works.  It returns an XML file, are there scripts to process it?
Can there be in the frame like a search box or something that uses that information to call with?  The example call shows that you need both your ID and the ZPID, but how does that work in a form?
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 18 2009
Profile picture for Nexus Software
If you are going top use the API, why use frames? Using the API you have the opportunity to display the data on the same page as the rest of your content. The processing of the API data is easily accomplished in a variety of programming languages. The choice of which would be based on the language of the rest of your site and your server's environment.
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 18 2009
Profile picture for darryll
Mr. Silver, how?
I am just trying to get this going for a friend that has this Zillow account, he had someone build his website but it is all tables and yuck.  I would prefer not to use a frame. 
Are there examples of this processing?
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 18 2009
Profile picture for Nexus Software
We are putting together an examples page. Which particular API call did your friend want to retrieve data from?
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 18 2009
Profile picture for Nexus Software
 I just noticed you referenced the zestimate API. Though, the other webservices are able to processed in the same manner.

Once we have an examples page up. I'll include information about some ways that the examples could be implemented.
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 18 2009
Profile picture for darryll
Thanks for all your help here man, I appreciate it.  Thought this might help, see he used to have a valuation page that iframed in an API call but then he got an email saying the API was no longer valid or something.  It used to do this,

    "it used to be was a box framed in where you could type in any address and get the value of that address plus other characteristics of that property."

So he wants to replicate that best as can I assume with the new API.  Can you offer suggestions? Does that make sense?  Thanks.
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 18 2009
Profile picture for Nexus Software
It does make sense. Do you know what type of server his site is on, Linux or Windows? What is the URL of his site?
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 18 2009
Profile picture for darryll
It is on a Linux server,

edit- running PHP5

94598homes.com
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 18 2009
Profile picture for Nexus Software
Okay, we are working on a few PHP examples now.
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 19 2009
Profile picture for darryll
Thanks, any ETA?
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 19 2009
Profile picture for Nexus Software
Now. Here is a simple example that was put together in about 10 minutes.

http://nexwebsites.com/Real-Estate/Zestimate.htm

The Gist of it is to get the variables via your form, in this case 'Street'  and 'City State or Zip' append those variable to your API call, retrieve the XML results and traverse the nodes assigning the XML elements to your variables. Then it is just a matter of writing your variables where you would like them to be on your page.

Another example is for Regional Listings is : http://nexwebsites.com/Real-Estate/Zillow-Listings.htm
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
June 22 2009
Profile picture for darryll
Hey there, how is the tutorials coming along?  Any PHP examples yet?  I have been trying to implement what you posted in your last, but frankly I am lost.  I do not see anywhere in the code on that page where anything is called, I see a form that posts to itself, no calls elsewhere.  So I don't see how it works.  Can you please tell me?
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 06 2009
Profile picture for Nexus Software
About the only thing easier than using than using a REST based webservice is kicking in a couple of bucks to have a developer do it for you.

1.)You call the API's URL with your script, specifying the variables that you obtained with your form.
2.)The webservice returns XML relevant to the request that you made with your call.
3.)Your script parses the XML by walking the nodes and storing the results in some new temporary variables.  

Echo, echo. Is there an echo in here?
Echo these variables where you would like them to be on your generated page.
That's all she wrote. Your done. Except for maybe a little formatting of the page, with pretty colors and such.
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 07 2009
Profile picture for darryll
Right no I understand that, but where is the script? On that example link you posted, I looked at the source but only see a form.  Where do the variables go?  I did not see a PHP script in there....
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 07 2009
Profile picture for Nexus Software
Are you looking for cut and paste solution?  If you are at all interested in learning how to do it, you should work it out on your own. Here is a nugget to get you started with the Zestimate API.
Replace YOUR_ZILLOW_ID with your Zillow id:

<?php
//Copyright © Nexus Software Systems - http://nexwebsites.com
if(isset($_POST['street']))
{
$street = urlencode(htmlentities(strip_tags(trim($_POST['street'])))); 
}
if(isset($_POST['citystatezip']))
{
   echo "<table border=\"1\" id=\"example\" border=\"0\" cellpadding=\"0\" cellspacing=\"1\">
<thead><tr><th>Address</th><th>City     </th><th>State     </th><th>ZipCode     </th><th>Zestimate     </th><th>Low Range    </th><th>High Range   </th><th>ZPID    </th></tr>";
$citystatezip = urlencode(htmlentities(strip_tags(trim($_POST['citystatezip']))));
     } else   {
exit;
}
$rss =  simplexml_load_file('http://www.zillow.com/webservice/GetSearchResults.htm?zws-id=YOUR_ZILLOW_ID&address='.$street.'&citystatezip='.$citystatezip);

// Here we'll put a loop to include each item's title and description
foreach ($rss->xpath('//response//result') as $title) {

 echo "<tr><td><a target=_blank href='" . $title->links->homedetails . "?scrnnm=Nexus-Software'>" . $title->address->street . "</a></td><td>". $title->address->city ."</td><td>". $title->address->state."</td><td>". $title->address->zipcode ."</td><td>$". $title->zestimate->amount."</td><td>$". $title->zestimate->valuationRange->low."</td><td>$". $title->zestimate->valuationRange->high."</td><td>". $title->zpid."</td></tr>";
                 
}
?></td></tr></table>
<br /><br /> <br /><font>Powered by <a href="http://nexwebsites.com" target="_top">Nexus
Software Systems </a></font>
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 07 2009
Profile picture for darryll
Thank you, see that makes sense to me, but where was that script?  My problem is not the PHP, I mean I am still learning but I can follow it, I just did not see where the form fields got sent to that script, does that make sense? 
Thanks a lot for all your indulgence. :)
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 07 2009
Profile picture for Nexus Software
 Are you all set now?  You were looking at the output of the script. And actually that generated page with the form, goes at the top of the script, before the PHP block.
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 07 2009
Profile picture for darryll
It is not letting post in here very well, keeps giving me invalid html error, but no html :)

Why does the PHP not show in the source code?  I could not see how and where the API was being called. 
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 07 2009
Profile picture for Nexus Software
In the source code of what? The generated page? This isn't like pasting in a widget. Everything is dynamically generated. That's one of the beauties of using the API.  Your results, defined and formatted exactly the way you would like them to be.

The API is being called with the following:

$rss = simplexml_load_file('http://www.zillow.com/webservice/GetSearchResults.htm?zws-id=YOUR_ZILLOW_ID&address='.$street.'&citystatezip='.$citystatezip);

  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 07 2009
Profile picture for darryll
Right thanks, and I see how it concatenates the form values grabbed during post, I guess at this point I am just wondering why I could not see the PHP before, all I saw was a form posting itself with no calls, know what I mean?

So all the submit button does is repost the page and then the variables are populated and sent to zillow then it just parses the XML return in a variable to traverse, and display.  Is that about right?
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 07 2009
Profile picture for Nexus Software
Yes, that's it. PHP is so blah though. It get's the job done, sort of, and sometimes it is easier using PHP. But doing the same thing and more with .Net is often even simpler and a lot more sexy. I guess for me that means the language constructs are so much more organized, well thought out and functional. I didn't always feel that way, been writing in PHP since it first came out, but Microsoft has really gone all out with the latest releases of the .Net Framework. I better stop here, I could go on for days expounding on the benefits of .Net.
 A very basic example, written in .Net utilizing only the minimum number of fields is at: http://nexwebsites.com/Real-Estate/Portland-Maine/
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 07 2009
Profile picture for darryll
I am still new to PHP, really to all web dev stuff, the only .NET I am familiar with is the SDK I used when learning C++ back in Visual Studio.  Though now I cant stand to use the IDE :)
I like the OO parts of PHP though, because classes and structs were my norm for a while, and the object aspect of it all is familiar at least.

Can you tell me though, last question I hope :)  where is the PHP on your first example site, the http://nexwebsites.com/Real-Estate/Zestimate.htm one ?  Why in the source is there no <?php ... ?>  ?
  Flag content
Close
Report a Problem

Please enter a valid email address.

Close
Content flagged

We will review this content. Thanks for helping make the site more useful to everyone. To learn more, read Zillow's Good Neighbor Policy.

Close
We're Sorry
This service is temporarily unavailable. Please come back later and try again.
July 07 2009
 
  • Be a Good Neighbor. Be respectful and on-topic. No spam or self-promotion! See our Good Neighbor Policy.

Have a question? Ask it here.

What's this?
Close

By starting a discussion, you can expect more of an interactive, back-and-forth experience where the conversation can go in many different directions.

Or start a discussion
Related Discussions
Profile picture for HomeSand.net
DiscussionGetDeepSearchResults return error 508
  • Last reply by HomeSand.net
  • April 24
Profile picture for user801340
Discussionneighborhood boundary shapefiles - Berkeley, CA?
  • Posted by user801340
  • April 19
Profile picture for Matthew Z CS
Discussionfacebook apps
  • Last reply by Matthew Z CS
  • April 12
Profile picture for Matt Bowers
DiscussionZillow neighborhood data for mobile apps
  • Last reply by Matt Bowers
  • April 06
Profile picture for joeboyscout04
Discussionmobile app development
  • Last reply by joeboyscout04
  • March 22
Be A Good Neighbor

Zillow® Advice depends on each member to keep it a safe, fun, and positive place. If you see abuse, flag it. More on our Good Neighbor Policy