SlideShare a Scribd company logo
How to Integrate Text
and Phone Messaging
with Your Website
by Cindy Cullen
cindycullen.com
Programming since 1983
Building websites since 1999
Freelance web developer since 2003
Cell phone user since they were too big to carry
Taught Computers to children and adults – Online,
Homeschool co-ops, Elementary School, Junior High,
High School, College, Seminars
Messages
MyOutdoorCalendar.com
Images courtesy of vectorolie / FreeDigitalPhotos.net
We tried…
“We need phone calls and text messages”
Email Mobile Apps
Image courtesy of zirconicusso /
FreeDigitalPhotos.net
Short Codes
O Five digit number
O About $1000+/month
O Long application approval process
Shared Short Codes
O Buy Keyword(s) – about $25/month
O Phone numbers – about $3/month
O Voice – about $0.05/minute
O Text - about $0.05/minute
O Bulk Monthly plans usually available
Images courtesy of vectorolie / FreeDigitalPhotos.net
BowlingGreenMassage.com
Mass Text
Database of phone numbers
Opening today at 3pm
Openingtodayat3pm
Web Meets Messaging with
10 digit phone numbers
O Twilio
O Tropo
O Plivo
O Nexmo
How it Works
O Buy Phone Number (or short code)
O Receive messages on my website
O Call or Text that number
O Twilio/Tropo/Plivo/Nexmo sends the message to
my URL
O My website processes the message and
responds (usually with XML)
O Send messages from my website
O My website sends instructions to that number
using a provided library and API
Pricing
O Phone Numbers
O $0.80/month - $3/month (Avg. $1/month)
O Voice
O Inbound $0.0050/min – $0.03/min (Avg.
$0.01/min)
O Outbound $0.0130/min – $0.03/min (Avg.
$0.02/min)
O SMS
O Inbound Free – $0.01/msg (Avg $0.0075/msg)
O Outbound $0.0065/msg - $0.01/msg (Avg.
$0.0075/msg)
My Pick
Twilio
O Average pricing
O Great documentation
O Great tutorials
O Subaccounts
O Analytics
O Developer tools
O Triggers
O Easiest to get up and running for ME
Mass Text
Database of phone numbers
Opening today at 3pm
Openingtodayat3pm
Sent to My Script
require "Services/Twilio.php";
$AccountSid = “Bxxxxxxx”;
$AuthToken = “2xxxxxxxx";
$client = new Services_Twilio($AccountSid, $AuthToken);
$twilio_number = “615-555-0123”;
If ($_POST[‘From’] == $twilio_number) {
$body =;
$users = get_users('meta_key=phone');
$special_chars = array("-","(",")");
foreach ($users as $user) {
$phone = '+1'.str_replace($special_chars,"",get_user_meta($user->ID, 'phone', true));
$numbers[] = $phone;
}
foreach ($numbers as $number) {
$sms = $client->account->messages->sendMessage($twilio_number, $number,
$_POST[‘Body’]);
}
} else {
// Process user message
}
Respond to Text
<?php
header(“content-type: text/xml”);
echo “<?xml version=”1.0” encoding=”UTF-8”
?>n”;
?>
<Response>
<Message>Thanks <?php echo $name ?> for
your response.</Message>
</Response>
CloneMeServices.com
Dial 1 for
emergency
Dial 2 to leave a message
Image courtesy of Stuart Miles /FreeDigitalPhotos.net
When the number is called…
<?php date_default_timezone_set('America/Chicago');
header("content-type: text/xml");
echo "<?xml version="1.0" encoding="UTF-8"?>n";
if (date("H") > '20') : // time later than 9PM? ?>
<Response>
<Gather action="/user-input" numDigits="1">
<Say>Welcome to Clone Me Services.</Say>
<Say>If this is an emergency please press 1</Say>
<Say>Otherwise, please press2</Say>
</Gather>
<Say>Sorry, I didn't get your response.</Say>
<Redirect>/phone</Redirect>
</Response>
<?php else: ?> // time before 9PM, just forward
<Response>
<Dial>+12707916649</Dial>
</Response>
<?php endif; ?>
User presses number…
<?php // if the caller pressed anything but 1 or 2 send them back
if($_REQUEST['Digits'] != '1' and $_REQUEST['Digits'] != '2') {
header("Location: /phone");
die;
}
// otherwise, if 1 was pressed we Dial CloneMeServices. If 2 we make an audio
recording up to 30 seconds long.
header("content-type: text/xml");
echo "<?xml version="1.0" encoding="UTF-8"?>n”; ?>
<Response>
<?php if ($_REQUEST['Digits'] == '1') { ?>
<Dial>+16155551111</Dial>
<Say>The call failed or the remote party hung up. Goodbye.</Say>
<?php } elseif ($_REQUEST['Digits'] == '2') { ?>
<Say>Record your message after the tone.</Say>
<Record maxLength="30" action="/after-recording" />
<?php } ?>
</Response>
After the recording…
<?php
header("content-type: text/xml");
echo "<?xml version="1.0" encoding="UTF-8"?>n";
?>
<Response>
<Say>Thanks for your message.
Goodbye.</Say>
</Response>
Image courtesy of zirconicusso /
FreeDigitalPhotos.net
Applications
O Appointment Reminders
O Call Queue’s – matching callers and
agents
O Call Screening – find a live body to
answer
O Call Metrics
O Click to Call – button on website (calls to
or from browsers or mobile devices
$0.0025/min)
O Automated Phone System
More Applications
O Conference Calls
O Phone Polls
O Voice Broadcast
O Voicemail
O Voice Transcription
O Audio Recording from your Website
O Browser Phone
O Browser to Browser Calls
And More!
O Group Chat
O Text to Speech
O SMS notifications
O SMS from a call
O MMS (some may support – only on short
codes with twilio)
Who Will Want This?
O Doctors
O Dentists
O Hair and Nail Salons
O Massage Therapists
O Other Professional Services
O Marketers (careful with bulk messaging!)
O Dry Cleaners
O Restaurants
Who Can Use this?
O Schools
O Clubs and Groups
O Churches
O Political Groups
O Fitness Centers & Sports Clubs
O Anybody!

More Related Content

PDF
Afrika rastlinstvo a živočíšstvo
PDF
Look Who's Talking
PDF
Phone calls and sms from php
PPTX
Security - 101 - ISSA
PPTX
Cassandra & puppet, scaling data at $15 per month
PDF
My app is secure... I think
PPT
Ims Gc 2007 V2
PPTX
UCloud Asia Company Presentation - How to prevent Ransomware and Phishing att...
Afrika rastlinstvo a živočíšstvo
Look Who's Talking
Phone calls and sms from php
Security - 101 - ISSA
Cassandra & puppet, scaling data at $15 per month
My app is secure... I think
Ims Gc 2007 V2
UCloud Asia Company Presentation - How to prevent Ransomware and Phishing att...

Similar to How to Integrate Text and Phone Messaging with your Website (20)

PPTX
UCloud Asia Company Presentation
PDF
BI temps réel et notifications en situation de mobilité à partir d'objets con...
PDF
BI temps réel et notifications en situation de mobilité à partir d'objets con...
PDF
Improve Your Salesforce Efficiency: Formulas for the Everyday Admin
PDF
Improve Your Salesforce Efficiency: Formulas for the Everyday Admin
PPTX
PHP & Twilio
PPTX
Productizing Twilio Applications
PPTX
Voice Summit 2018 - Millions of Dollars in Helping Customers Through Searchin...
ODP
My app is secure... I think
PDF
SAMEER MALIK RP
ODP
Beyond php it's not (just) about the code
KEY
I18n
PPTX
Modern ICT (Information and Communication technology on secretary.pptx
PPTX
광운대학교 2014 공진흥교수님_퀵스팀_백병화_김경민_장용준_이종우
PPT
Tech Tips (NLADA Substantive Law Conference 2010)
PDF
Twilio Messaging: Overview and New Feature Deep Dive
PDF
Salesforce Admin Hack Series: Case Object
PPTX
BOOM Performance
PPTX
YGLF 2015 - Boom Performance | Eran Zinman (daPulse)
PPTX
Word press security 101
UCloud Asia Company Presentation
BI temps réel et notifications en situation de mobilité à partir d'objets con...
BI temps réel et notifications en situation de mobilité à partir d'objets con...
Improve Your Salesforce Efficiency: Formulas for the Everyday Admin
Improve Your Salesforce Efficiency: Formulas for the Everyday Admin
PHP & Twilio
Productizing Twilio Applications
Voice Summit 2018 - Millions of Dollars in Helping Customers Through Searchin...
My app is secure... I think
SAMEER MALIK RP
Beyond php it's not (just) about the code
I18n
Modern ICT (Information and Communication technology on secretary.pptx
광운대학교 2014 공진흥교수님_퀵스팀_백병화_김경민_장용준_이종우
Tech Tips (NLADA Substantive Law Conference 2010)
Twilio Messaging: Overview and New Feature Deep Dive
Salesforce Admin Hack Series: Case Object
BOOM Performance
YGLF 2015 - Boom Performance | Eran Zinman (daPulse)
Word press security 101
Ad

More from Cindy Cullen (6)

PPTX
Taking Code on the Road CoderCruise
PPTX
Taking code on the road for WordCamp Asheville
PPTX
Taking code on the road
PPTX
Freelancing: How to Get Started... or Not.
PPTX
WordPress developer 101
PPTX
The Care and Feeding of Your WordPress Website - Hosting, Updates, Backups, S...
Taking Code on the Road CoderCruise
Taking code on the road for WordCamp Asheville
Taking code on the road
Freelancing: How to Get Started... or Not.
WordPress developer 101
The Care and Feeding of Your WordPress Website - Hosting, Updates, Backups, S...
Ad

Recently uploaded (20)

PPT
Design_with_Watersergyerge45hrbgre4top (1).ppt
PPT
tcp ip networks nd ip layering assotred slides
PPTX
PptxGenJS_Demo_Chart_20250317130215833.pptx
PDF
SASE Traffic Flow - ZTNA Connector-1.pdf
PDF
Testing WebRTC applications at scale.pdf
PPTX
Introduction about ICD -10 and ICD11 on 5.8.25.pptx
PPTX
artificial intelligence overview of it and more
PPTX
Internet___Basics___Styled_ presentation
PPTX
522797556-Unit-2-Temperature-measurement-1-1.pptx
PPTX
Funds Management Learning Material for Beg
PDF
Tenda Login Guide: Access Your Router in 5 Easy Steps
PDF
Paper PDF World Game (s) Great Redesign.pdf
PDF
RPKI Status Update, presented by Makito Lay at IDNOG 10
PDF
Automated vs Manual WooCommerce to Shopify Migration_ Pros & Cons.pdf
PDF
APNIC Update, presented at PHNOG 2025 by Shane Hermoso
PPTX
Introuction about WHO-FIC in ICD-10.pptx
PDF
Vigrab.top – Online Tool for Downloading and Converting Social Media Videos a...
PPTX
international classification of diseases ICD-10 review PPT.pptx
PDF
Sims 4 Historia para lo sims 4 para jugar
PDF
WebRTC in SignalWire - troubleshooting media negotiation
Design_with_Watersergyerge45hrbgre4top (1).ppt
tcp ip networks nd ip layering assotred slides
PptxGenJS_Demo_Chart_20250317130215833.pptx
SASE Traffic Flow - ZTNA Connector-1.pdf
Testing WebRTC applications at scale.pdf
Introduction about ICD -10 and ICD11 on 5.8.25.pptx
artificial intelligence overview of it and more
Internet___Basics___Styled_ presentation
522797556-Unit-2-Temperature-measurement-1-1.pptx
Funds Management Learning Material for Beg
Tenda Login Guide: Access Your Router in 5 Easy Steps
Paper PDF World Game (s) Great Redesign.pdf
RPKI Status Update, presented by Makito Lay at IDNOG 10
Automated vs Manual WooCommerce to Shopify Migration_ Pros & Cons.pdf
APNIC Update, presented at PHNOG 2025 by Shane Hermoso
Introuction about WHO-FIC in ICD-10.pptx
Vigrab.top – Online Tool for Downloading and Converting Social Media Videos a...
international classification of diseases ICD-10 review PPT.pptx
Sims 4 Historia para lo sims 4 para jugar
WebRTC in SignalWire - troubleshooting media negotiation

How to Integrate Text and Phone Messaging with your Website

  • 1. How to Integrate Text and Phone Messaging with Your Website
  • 2. by Cindy Cullen cindycullen.com Programming since 1983 Building websites since 1999 Freelance web developer since 2003 Cell phone user since they were too big to carry Taught Computers to children and adults – Online, Homeschool co-ops, Elementary School, Junior High, High School, College, Seminars
  • 5. Images courtesy of vectorolie / FreeDigitalPhotos.net
  • 6. We tried… “We need phone calls and text messages” Email Mobile Apps
  • 7. Image courtesy of zirconicusso / FreeDigitalPhotos.net
  • 8. Short Codes O Five digit number O About $1000+/month O Long application approval process
  • 9. Shared Short Codes O Buy Keyword(s) – about $25/month O Phone numbers – about $3/month O Voice – about $0.05/minute O Text - about $0.05/minute O Bulk Monthly plans usually available
  • 10. Images courtesy of vectorolie / FreeDigitalPhotos.net
  • 12. Mass Text Database of phone numbers Opening today at 3pm Openingtodayat3pm
  • 13. Web Meets Messaging with 10 digit phone numbers O Twilio O Tropo O Plivo O Nexmo
  • 14. How it Works O Buy Phone Number (or short code) O Receive messages on my website O Call or Text that number O Twilio/Tropo/Plivo/Nexmo sends the message to my URL O My website processes the message and responds (usually with XML) O Send messages from my website O My website sends instructions to that number using a provided library and API
  • 15. Pricing O Phone Numbers O $0.80/month - $3/month (Avg. $1/month) O Voice O Inbound $0.0050/min – $0.03/min (Avg. $0.01/min) O Outbound $0.0130/min – $0.03/min (Avg. $0.02/min) O SMS O Inbound Free – $0.01/msg (Avg $0.0075/msg) O Outbound $0.0065/msg - $0.01/msg (Avg. $0.0075/msg)
  • 17. Twilio O Average pricing O Great documentation O Great tutorials O Subaccounts O Analytics O Developer tools O Triggers O Easiest to get up and running for ME
  • 18. Mass Text Database of phone numbers Opening today at 3pm Openingtodayat3pm
  • 19. Sent to My Script
  • 20. require "Services/Twilio.php"; $AccountSid = “Bxxxxxxx”; $AuthToken = “2xxxxxxxx"; $client = new Services_Twilio($AccountSid, $AuthToken); $twilio_number = “615-555-0123”; If ($_POST[‘From’] == $twilio_number) { $body =; $users = get_users('meta_key=phone'); $special_chars = array("-","(",")"); foreach ($users as $user) { $phone = '+1'.str_replace($special_chars,"",get_user_meta($user->ID, 'phone', true)); $numbers[] = $phone; } foreach ($numbers as $number) { $sms = $client->account->messages->sendMessage($twilio_number, $number, $_POST[‘Body’]); } } else { // Process user message }
  • 21. Respond to Text <?php header(“content-type: text/xml”); echo “<?xml version=”1.0” encoding=”UTF-8” ?>n”; ?> <Response> <Message>Thanks <?php echo $name ?> for your response.</Message> </Response>
  • 22. CloneMeServices.com Dial 1 for emergency Dial 2 to leave a message Image courtesy of Stuart Miles /FreeDigitalPhotos.net
  • 23. When the number is called… <?php date_default_timezone_set('America/Chicago'); header("content-type: text/xml"); echo "<?xml version="1.0" encoding="UTF-8"?>n"; if (date("H") > '20') : // time later than 9PM? ?> <Response> <Gather action="/user-input" numDigits="1"> <Say>Welcome to Clone Me Services.</Say> <Say>If this is an emergency please press 1</Say> <Say>Otherwise, please press2</Say> </Gather> <Say>Sorry, I didn't get your response.</Say> <Redirect>/phone</Redirect> </Response> <?php else: ?> // time before 9PM, just forward <Response> <Dial>+12707916649</Dial> </Response> <?php endif; ?>
  • 24. User presses number… <?php // if the caller pressed anything but 1 or 2 send them back if($_REQUEST['Digits'] != '1' and $_REQUEST['Digits'] != '2') { header("Location: /phone"); die; } // otherwise, if 1 was pressed we Dial CloneMeServices. If 2 we make an audio recording up to 30 seconds long. header("content-type: text/xml"); echo "<?xml version="1.0" encoding="UTF-8"?>n”; ?> <Response> <?php if ($_REQUEST['Digits'] == '1') { ?> <Dial>+16155551111</Dial> <Say>The call failed or the remote party hung up. Goodbye.</Say> <?php } elseif ($_REQUEST['Digits'] == '2') { ?> <Say>Record your message after the tone.</Say> <Record maxLength="30" action="/after-recording" /> <?php } ?> </Response>
  • 25. After the recording… <?php header("content-type: text/xml"); echo "<?xml version="1.0" encoding="UTF-8"?>n"; ?> <Response> <Say>Thanks for your message. Goodbye.</Say> </Response>
  • 26. Image courtesy of zirconicusso / FreeDigitalPhotos.net
  • 27. Applications O Appointment Reminders O Call Queue’s – matching callers and agents O Call Screening – find a live body to answer O Call Metrics O Click to Call – button on website (calls to or from browsers or mobile devices $0.0025/min) O Automated Phone System
  • 28. More Applications O Conference Calls O Phone Polls O Voice Broadcast O Voicemail O Voice Transcription O Audio Recording from your Website O Browser Phone O Browser to Browser Calls
  • 29. And More! O Group Chat O Text to Speech O SMS notifications O SMS from a call O MMS (some may support – only on short codes with twilio)
  • 30. Who Will Want This? O Doctors O Dentists O Hair and Nail Salons O Massage Therapists O Other Professional Services O Marketers (careful with bulk messaging!) O Dry Cleaners O Restaurants
  • 31. Who Can Use this? O Schools O Clubs and Groups O Churches O Political Groups O Fitness Centers & Sports Clubs O Anybody!

Editor's Notes

  • #3: Web developer, cell phone user, teacher.
  • #4: We have email, phone, text messages, phone apps. It’s time that we integrate all of them and make them work for us.
  • #5: My story – started MOC: Booking tool for Hunting and Fishing guides. Guides needed to confirm or deny trips from the field. They needed a way to send and receive text messages to and from the website.
  • #7: The standard ways to communicate weren’t going to work for hunting and fishing guides very well.
  • #8: Learning how to make MOC work gave me lots of other ideas about hooking phones and text messaging
  • #12: Wanted to send text messages to clients when she had cancellations or openings for the day. Also to send out specials.
  • #27: Learning how to make MOC work gave me lots of other ideas about hooking phones and text messaging