Advertisement
urosevic

Process shortcodes in Image Map Pro for WordPress

Mar 30th, 2016
213
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2. /**
  3.  * Enable shortcode processing in Tooltip Content: Image Map Pro for WordPress - Interactive Image Map Builder
  4.  * http://codecanyon.net/item/image-map-pro-for-wordpress-interactive-image-map-builder/2826664?ref=urosevic
  5.  * Author: Aleksandar Urosevic https://urosevic.net
  6.  * Add to line 125, after `$save = $options['saves'][$i];` code below:
  7.  */
  8.  
  9. for ($s=0; $s<count($save['spots']); $s++) {
  10.     $save['spots'][$s]['tooltip_content']['text'] = addslashes( do_shortcode( stripslashes( $save['spots'][$s]['tooltip_content']['text'] ) ) );
  11. }
Advertisement
RAW Paste Data Copied
Advertisement