| 1 |
<?php |
| 2 |
function virtue_toolkit_columns_ajax_tinymce() { |
| 3 |
if (!current_user_can('edit_pages') && !current_user_can('edit_posts')){ |
| 4 |
die(__("You are not allowed to be here")); |
| 5 |
} |
| 6 |
|
| 7 |
include_once( dirname(dirname(__FILE__)) . '/virtue-toolkit/shortcodes/columns/columns_popup.php'); |
| 8 |
} |
| 9 |
add_action('wp_ajax_kadcolumns_tinymce', 'virtue_toolkit_columns_ajax_tinymce'); |
| 10 |
|
| 11 |
function virtue_toolkit_icons_ajax_tinymce() { |
| 12 |
if (!current_user_can('edit_pages') && !current_user_can('edit_posts')) { |
| 13 |
die(__("You are not allowed to be here")); |
| 14 |
} |
| 15 |
|
| 16 |
include_once( dirname(dirname(__FILE__)) . '/virtue-toolkit/shortcodes/icons/icon_popup.php'); |
| 17 |
} |
| 18 |
add_action('wp_ajax_kadicons_tinymce', 'virtue_toolkit_icons_ajax_tinymce'); |
| 19 |
|
| 20 |
function virtue_toolkit_quote_ajax_tinymce() { |
| 21 |
if (!current_user_can('edit_pages') && !current_user_can('edit_posts')) { |
| 22 |
die(__("You are not allowed to be here")); |
| 23 |
} |
| 24 |
|
| 25 |
include_once( dirname(dirname(__FILE__)) . '/virtue-toolkit/shortcodes/pullquote/quote_popup.php'); |
| 26 |
} |
| 27 |
add_action('wp_ajax_kadquote_tinymce', 'virtue_toolkit_quote_ajax_tinymce'); |
| 28 |
|
| 29 |
function virtue_toolkit_youtube_ajax_tinymce() { |
| 30 |
if (!current_user_can('edit_pages') && !current_user_can('edit_posts')) { |
| 31 |
die(__("You are not allowed to be here")); |
| 32 |
} |
| 33 |
|
| 34 |
include_once( dirname(dirname(__FILE__)) . '/virtue-toolkit/shortcodes/youtube/youtube_popup.php'); |
| 35 |
} |
| 36 |
add_action('wp_ajax_kadyoutube_tinymce', 'virtue_toolkit_youtube_ajax_tinymce'); |
| 37 |
|
| 38 |
function virtue_toolkit_vimeo_ajax_tinymce() { |
| 39 |
if (!current_user_can('edit_pages') && !current_user_can('edit_posts')) { |
| 40 |
die(__("You are not allowed to be here")); |
| 41 |
} |
| 42 |
|
| 43 |
include_once( dirname(dirname(__FILE__)) . '/virtue-toolkit/shortcodes/vimeo/vimeo_popup.php'); |
| 44 |
} |
| 45 |
add_action('wp_ajax_kadvimeo_tinymce', 'virtue_toolkit_vimeo_ajax_tinymce'); |
| 46 |
|
| 47 |
function virtue_toolkit_btns_ajax_tinymce() { |
| 48 |
if (!current_user_can('edit_pages') && !current_user_can('edit_posts')) { |
| 49 |
die(__("You are not allowed to be here")); |
| 50 |
} |
| 51 |
|
| 52 |
include_once( dirname(dirname(__FILE__)) . '/virtue-toolkit/shortcodes/btns/btns_popup.php'); |
| 53 |
} |
| 54 |
add_action('wp_ajax_kadbtns_tinymce', 'virtue_toolkit_btns_ajax_tinymce'); |
| 55 |
|
| 56 |
function virtue_toolkit_divider_ajax_tinymce() { |
| 57 |
if (!current_user_can('edit_pages') && !current_user_can('edit_posts')) { |
| 58 |
die(__("You are not allowed to be here")); |
| 59 |
} |
| 60 |
|
| 61 |
include_once( dirname(dirname(__FILE__)) . '/virtue-toolkit/shortcodes/divider/divider_popup.php'); |
| 62 |
} |
| 63 |
add_action('wp_ajax_kaddivider_tinymce', 'virtue_toolkit_divider_ajax_tinymce'); |
| 64 |
|
| 65 |
function virtue_toolkit_accordion_ajax_tinymce() { |
| 66 |
if (!current_user_can('edit_pages') && !current_user_can('edit_posts')) { |
| 67 |
die(__("You are not allowed to be here")); |
| 68 |
} |
| 69 |
|
| 70 |
include_once( dirname(dirname(__FILE__)) . '/virtue-toolkit/shortcodes/accordion/accordion_popup.php'); |
| 71 |
} |
| 72 |
add_action('wp_ajax_kadaccordion_tinymce', 'virtue_toolkit_accordion_ajax_tinymce'); |