added code to use submit button weight for passing in button location and success message toggle options.