GSoC CC WordPress Plugin: Weekly Report #12
erlehmann, August 19th, 2010
This may be my last report for the plugin. After 150 commits and a bit over 30KB of written PHP code, the Google Summer of Code proposal Support for CC licenses in WordPress is finally finished, though the final product is remarkably different from the original suggestion. As time went by fast in the last few days before the deadline, I successfully managed to fix the three remaining issues mentioned before; namely an IE bug, adding license information to the media manager overview table (screenshot) and having a proper README (written in Markdown).
However, one thing still did not work quite right: Embedding. A security restriction called the same origin policy prevents audio and video (but not images, as they came before the SOP) from one site to be included on another, unless a special HTTP header is sent. As Jonas Sicking puts it in an explanatory email (via):
Requiring that sites add ‘Access-Control-Allow-Origin:*’ simply is
a way for us to know that “this is a public resource that other sites
In addition to the above issue, other things should be taken care of server-side to ensure media playback works as intended:
- The X-Content-Duration header should tell the browser how long a media file is, in seconds. If it is not given, Browsers will have to figure out the duration by themselves, by seeking to the end of the file.
- gzip/deflate compression must not be used — if it is employed, Firefox will be unable to fast-forward, and Chrome will not play the given file at all.
- HTTP 1.1 byte range requests must be served correctly; otherwise there can be no seeking unless the relevant part of the file is already downloaded.
For many of these cases, if a server does not already handle them, only a few lines in the .htaccess file would need to be changed. But, as the plugin should also accommodate users who may not have the option, technical skill or time to edit their web server configuration, everything mentioned above needs to happen automagically. This has led me to writing a small web server and bundling it with the plugin.
Technical issues aside, participating in the Google Summer of Code was an interesting and unique experience that certainly made me grow in confidence regarding my abilities. I also learned to value how much work can go into a relatively small piece of code to create a sufficiently polished product. Finally, the plugin in its current incarnation was made possible only through assistance of the following people, whom I wish to thank:
- Matthias wetterfrosch Mehldau for a blog post regarding markup for creative-commons-licensed content
- Julia zeitrafferin Seeliger for a related article, the inspiring moment for me
- Johnny Häusler for a screenshot of the Spreeblick plugin interfaces
- Michelle Thorne for connecting me with a metadata expert
- Nathan Yergler for advising me on RDFa
- Nathan Kinkade for mentoring me over the course of the Google Summer of Code, continually suggesting code improvements and standing by to patiently explain issues until I got the point
- Moritz Metz for advising me to take non-standard WordPress directory names and post thumbnails into account
- Markus Beckedahl for suggesting the embed functionality
- Bernd Holzmüller for testing performance and explaining how to avoid memory leaks
What will follow now is user testing, hopefully yielding some real world experience and small improvements so a more polished version of the plugin can be packaged and released through the WordPress.org plugin directory. If, in the future, the plugin’s functionality is extended notably, I may write another blog post — for now, however, I’m done.