submit_to_remote fails on rails 2.2.2

submit_to_remote fails on rails 2.2.2 and rails 2.3.2 but fully
working with 2.0.2

please give me an answer as soon as possible. its very urgent

the code is

HTML