hook_uc_add_to_cart in template
I suspect the problem is that this hook can't be implemented in a template


Correct :) 

Only hook_theme(), preprocess hooks, and alter hooks can be implemented in template.php. For any others, including this one, you'll need to write a custom module.