define 2 functions for add short and long links