Added auto submit option, and updated example