开发者

Embed URL Link in SMS via PHP

Is there a way I can embed a URL link i.e. <a href='www.google.com'>google</a> in an SMS message send through [myphonenumber]@txt.att.net ? My mail configuration is set to "text/html" but the link shows up as un-clickab开发者_JAVA技巧le plain text in the SMS...

Any Ideas?!!?


Most phones will automatically linkify URLs, however it is not possible to give links the way you are trying to do. Simply send www.google.com and the receiving device will link it for you.


No, clickable links are dependent on the phone. Some phones will parse the SMS and make links "clickable", others won't.


SMS reader is NOT a webbrowser. Expecting a phone to render an SMS as a web page is pushing things.

Some phones have some smarts and will linkify URLs if they're spotted in there, but that's dependent on the phone.


Don't use HTML in your SMS message. SMS messages are supposed to be just text.

However, many handsets will make a URL interactive, just as text-only emails can have clickable in Outlook or GMail.

Remember:

  • Some handsets wont format the url in any special way so make sure the URL is easy to type out
  • It's general etiquette to allow people to unsubscribe. The last thing you want to do is spam people
  • SMS messages are restricted to 140 chars each so be careful of the URL size. You can go over that limit but it might become expensive.

So your SMS message should look something like this:

We have some great bargains. Log in at http://www.google.com or reply UNSUB


There are a lot of smartphones these days that might parse your HTML into a more intuitive, web browser kind of way, but this is not a good practice. You must use the URL or a better solution is create a tiny URL of your URL and send it in the SMS, this would save you a lot of characters. There is a wide range of URL shortening websites available, like bit.ly, goo.gl, ow.ly, tinyurl.com, etc.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜