Technical
Data circilation diagram
So here is just a simple explanation of how things work under the hood of the program... I guess it's fairly straightforward, php - xml - flash.
PHP page to retreive information from Freebase
For a few reasons I decided not to put the exact code of this php file online, but here is a pseudo-code version of it.
1) Initialize variables, import Freebase libraries, etc.
2) Buid my query which looks like the following : $query = array(array(
"type" => "/music/album",
"genre" => "Hip Hop",
"limit" => $no,
$res1 => array(),
$res2 => array(),
));
So this just looks for albums tagged with the genre "Hip Hop", and build 2 arrays : one for the album name the other for the artist name.
3) Next, I loop through all the albums/artists and try to find corresponding images if possible. If no image is to be found, it deletes the array element from our album and artist list, since we only want results with images!
4) Finally, I just use PHP to write my new XML file including the fresh data just collected.
Here's an example of what this page could return.
And the associated XML file.
Query examples VIA URL
http://www.freebase.com/api/service/mqlread?query={"query":[{"id":"/topic/en/edinburgh","key":[{"namespace":"/wikipedia/en_id","value":null}]}]}
http://www.freebase.com/api/service/mqlread?query={"query":[{"name":"Concordia University ","*":null}]}








