2010/6/9 Aaron Ward edugamer@gmail.com:
I finally had the time to dive back into this project and managed to get everything working exactly as I was hoping.... locally! After uploading the game to a server it suddenly stops working again. From my knowledge with Flash games and further testing, I believe it has to do with the cross-domain-policy for Wikitionary, which is usually an xml set up on the server.
While attempting to locate the current Wikimedia policy I ran into random comments with warnings about the security risks involved in using the cross-domain-policy. I also discovered that Bugfix 1.9 states "Partial support for Flash cross-domain-policy filtering."
I'm not sure where to go from here. Is there a confirmed and allowed method to programmatically pull the rendered HTML from Wiktionary that can then be parsed?
You can use JSON callbacks, which basically means you (dynamically) add something like this to the HTML of your page:
<script type="text/javascript" src="http://en.wiktionary.org/w/api.php?format=json&callback=myFunc¶metersHere"></script>
Which will cause the function myFunc() to be executed with the results of the API call passed as a parameter. However, for security reasons, all callbacks will be treated as originating from anonymous users, and they can't be used to get restricted informations, get tokens, edit stuff or anything like that.
Roan Kattouw (Catrope)