in reply to parameter passing problem
If you add a debugging display in test_format to show the contents of the $obj variable, you should see that it contains the word "input"