used JS to rewrite head/base/@href based on pathname. moved ie helper js to scripts dir