How to make links in a TextView clickable?

后端 未结 30 3272

I have the following TextView defined:



        
30条回答
  •  南方客
    南方客 (楼主)
    2020-11-21 23:43

    The reason you're having the problem is that it only tries to match "naked" addresses. things like "www.google.com" or "http://www.google.com".

    Running your text through Html.fromHtml() should do the trick. You have to do it programatically, but it works.

提交回复
热议问题