javascript fixes
more javascript fixes
javascript compatibility