bugfixes and crossbrowserfuck