WordPress.org

Ready to get started?Download WordPress

Plugin Directory

Link/Obfuscate Telephone Numbers

A shortcode to link to telephone numbers if the user is on a smartphone or leave plain text if not and then obfuscate the text/link. Example [link_obf

To use this plugin you can: 1. Upload the plugin folder to your "wp-content/plugins/" folder 1. Search from within the plugin screen in your admin pages for "Link/Obfuscate Telephone Numbers" You should then activate the plugin from within the plugin admin screen

To use the plugin place the shortcode [link_and_obfuscate_telephone_number] or [link_obfuscte_teleophone] where you want your code to appear. Inside the shortcode should be a minimum of a "tel" tag containing the telephone number you wish to act upon. Other options available are:

  • tel --> The number to you want to action
  • link --> enter link="0" to disable links
  • debug --> debug="1" will output debugging information
  • link_text --> Will change the link text eg link="Call Me"
  • non_mobile_text --> display different text/a different format to the user eg non_mobile_text= "+44 (0) 1226 123456"
  • css_class --> Surround the output in a custom class
  • mobile_css_class --> Apply a custom class to mobile only devices
  • non_mobile_css_class --> Apply a custom class to to non mobile devices
  • use_noscript_fallback --> Turn off the message
  • noscript_message --> customise the noscript message

Simple example

[link_and_obfuscate_telephone_number tel="1234567890"]

As an example you could use:

[link_and_obfuscate_telephone_number
    tel="1234567890"
    link="1"
    debug="0"
    link_text="Call Me"
    non_mobile_text="+44 (0) 01226 1234567"
    css_class="my_phone_number"
    mobile_css_class="mobile_device"
    non_mobile_css_class="non_mobile_device"
    use_noscript_fallback="1"
    noscript_message="JS not enabled"]

You may or may not be able to write the shortcode in the multiline format depending on your system configuration. If you are unable to then simply list the shortcode attributes on a single line

Requires: 3.0 or higher
Compatible up to: 3.7.1
Last Updated: 2013-11-7
Downloads: 1,342

Ratings

5 stars
5 out of 5 stars

Support

Got something to say? Need help?

Compatibility

+
=
Not enough data

0 people say it works.
0 people say it's broken.

100,1,1
100,1,1
100,1,1 100,1,1 100,1,1 100,1,1
100,1,1