Updated, refactored, added Chrome support