CRM-13745 - fix mysql exception

----------------------------------------
* CRM-13745: CRM_Contact_Form_Search_Custom_FullText: broken links from search results
  http://issues.civicrm.org/jira/browse/CRM-13745
Merge pull request #1962 from dlobo/CRM-13745

CRM-13745 - fix mysql exception