I need to make text within a UITextView to be clickable. Basically I want to show more information on the text being clicked on. In PHP I would surround the text I want clickable in square brackets and then make anything in square brackets a link (i.e. [More Info]). How can I do something similar in Swift? I know I can turn on data detectors to detect http links but I don't want http showing.
Asked
Active
Viewed 1,214 times
0
-
2I believe this is the same as the question that has been answered here, but in Obj-C: http://stackoverflow.com/questions/19332283/detecting-taps-on-attributed-text-in-a-uitextview-on-ios-7. If you only want to respond to taps on text by opening links, then you could use a UIWebView instead of UITextView. – Aurast Aug 25 '15 at 21:07
-
UIWebView was definitely the way to go. Thanks! – Floyd Resler Aug 26 '15 at 17:44