Fixed return instead of echo for submit.
Added submit test.