Code standards.

Included restoring the original datastream ID detection, which uses
the functions from Islandora to perform the heavy-lifting in reading
the DS-COMPOSITE-MODELs, instead of the custom code that was included.
Fix filter_xss() function call.
Fix initialization of static variable, and make error reporting consistent.