fixed resource mapping and tweaked header