Web APIs & plists

Keith of Imangi enlightened me. Instead of only serving JSON data in our web services, for iOS plists are even easier to use (they don’t require an additional library).

And it’s super simple to support both in a Python powered server, especially if the code is already dictionary based:
if format == “plist”:
from libs import plistlib
out.write(plistlib.writePlistToString(result))
else:
from django.utils import simplejson
out.write(simplejson.dumps(result))

If you find this helpful, make sure to check out Imangis games, especially Max Adventure <3

Leave a Reply

Your email address will not be published. Required fields are marked *

*

40,163 Spam Comments Blocked so far by Spam Free Wordpress

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>