On 09/04/2010 13:24, Matthew Somerville wrote:
Mitch Kent wrote:
I have anything a json request from the api would return, such as the
mp id or the original postcode used to search...

I don't know why it didn't have it before, but getMP results should now have a "url" field that is what you want.

is there a way to build a url such that theyworkforyou.com/mp/se11aa.html or similar will get me to the mp's page?

Alternatively, /mp/?p=<person ID> will work and redirect.

> Otherwise is there a systematic way to change the name/district
into a format to get to that page? (looks like theyworkforyou.com/mp/firstname_lastname/consituency but with spaces replaced with underscores... is that true for all results?)

The code is in www/includes/utility.php if you're interested, but probably not needed now. :)

ATB,
Matthew

_______________________________________________
Mailing list [email protected]
Archive, settings, or unsubscribe:
https://secure.mysociety.org/admin/lists/mailman/listinfo/developers-public
Blinder, ta very much :)

_______________________________________________
Mailing list [email protected]
Archive, settings, or unsubscribe:
https://secure.mysociety.org/admin/lists/mailman/listinfo/developers-public

Reply via email to