Using Iris Colorpicker on TinyMCE shortcodes page [duplicate]

Your problem probably is the following line in your JavaScript file: file : url.replace(‘/js’,”)+’../../tinymce_shortcode.php’ First, this way you’re bringing it out of context. Just load it up front when you init the plugin (and when you’re on a post.php or post-new.php request – see current_screen() return values to narrow that down to the needed requests … Read more

Custom Template Taxonomy

If I’m understanding your question correctly, you want to avoid code duplication among the three CPT archive and three taxonomy template files? If the point is primarily one of avoidance of code duplication (i.e. DRY – Don’t Repeat Yourself), I would recommend creating template part files for the loop content for each CPT: content-{cpt1}.php content-{cpt2}.php … Read more

upload file with front-end submission and forward the data in an email

In case anyone needs this, here is my solution: if ($_FILES) { function insert_attachment($file_handler, $post_id, $setthumb = ‘false’) { if ($_FILES[$file_handler][‘error’] !== UPLOAD_ERR_OK) __return_false(); require_once(ABSPATH . “wp-admin” . ‘/includes/image.php’); require_once(ABSPATH . “wp-admin” . ‘/includes/file.php’); require_once(ABSPATH . “wp-admin” . ‘/includes/media.php’); $attach_id = media_handle_upload( $file_handler, $post_id ); //get url $attachment_url = wp_get_attachment_url($attach_id); add_post_meta($post_id, ‘_file_paths’, $attachment_url); $attachment_data = … Read more

RSS Feed Broken – Limit?

Ok, nevermind… We figured out we can pull individual feeds for each categories and so we set the general overall limit back to 10. And here is function to override general limit. function custom_rss_limits($limits) { if (is_feed() && is_category(‘category-slug’)) { // target a specific feed category and set a unique limit return “LIMIT 0, 20”; … Read more

hatom-feed entry-title error in the rich snippets tool

Look at your page source and see if your html markup actually contains the entry-title class, i.e.: <h1 class=”entry-title”>My Page Title</h1> as it must for the span and other classes for date and author. If it does, clear your cache and try Google’s testing tool again. If your page source does not contain the correct … Read more

How to change value of $menu_class in ep_nav_menu?

There is no need to add any code for this. You can use the Screen Options on the menu admin end to achieve this. Please check the instructions below. Login to the admin end of your wordpress site and navigate to Appearance => Menus section. Click the down arrow against the menu item you need … Read more