Skip to content

Instantly share code, notes, and snippets.

@kageroh
Created March 16, 2011 02:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kageroh/871888 to your computer and use it in GitHub Desktop.
Save kageroh/871888 to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="shift_jis"?>
<job>
<script language="JScript"><![CDATA[
(function() {
var dom;
try { dom = new ActiveXObject('Msxml2.DOMDocument.4.0'); }
catch (e) { dom = new ActiveXObject('Microsoft.XMLDOM'); }
dom.async = false;
dom.resolveExternals = true;
dom.validateOnParse = true;
for (var path, results = [], args = WSH.arguments, i = args.length; i--;) {
dom.load(path = args(i));
with (dom.parseError)
results.push(path + '\n' + (errorCode !== 0 ? [line, linepos, reason] + srcText : 'Valid XML'));
}
WSH.echo(results.join('\n\n'));
})();
]]></script>
</job>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment