test if li element is defined before calling pos_phone or pos_default functions to avoid undefined error when resizing the window.
Fix for the undefined error in Joyride