upgraded jQuery to v2.1.0 and changed var to val