do not check file: check http: and https: instead (eg phonegap on wp8 has protocol x-wmapp0:)