more fixes for link_to_function problems