work in progress
Clearify why I made this
simplify script to only work in current browsers