front post submit using wp_editor

If you want to add a new post without logging into the WordPress dashboard or allow your visitors a way to submit content of their own, you can do this by front end post submission. In this post I will show you the way to submit a post from the front end. Let’s start… You … Read more

js code not stored in database currectly

If you search WordPress core for < or > you will find the function _wp_specialchars in /wp-includes/formatting.php Then if you search for _wp_specialchars you will see it is used in esc_js (as well as esc_html and esc_attr) so do not use esc_js, escaping is mostly for output anyway. Further search results show that in /wp-includes/default-filters.php … Read more

Links not showing up on “AMPforWP”

i didn’t use this plugin but if i were you i use .htacces to redirect mobiles users to amp url Assuming your amp version is under /amp (http://example.com/amp), you can try redirecting your visitors in your .htaccess file like this: RewriteEngine On RewriteCond %{REQUEST_URI} !/amp$ [NC] RewriteCond %{HTTP_USER_AGENT} (android|blackberry|googlebot\-mobile|iemobile|iphone|ipod|\#opera\ mobile|palmos|webos) [NC] RewriteRule ^([a-zA-Z0-9-]+)([\/]*)$ https://example.com/$1/amp [L,R=302] … Read more

Add Condition if WPBakery Page Builder Used on Page or Not

Some quick answer you can achieve what you want to do. There is a filter which check if the current page post type is available for using WPBaker called `vc_is_valid_post_type_be’ and there you can manage “can” or “cannot” to load it. add_filter(‘vc_is_valid_post_type_be’, ‘wpse308043_vc_is_valid_post_type_be’, 10, 2); function wpse308043_vc_is_valid_post_type_be($checked_type, $type) { global $post; if($post->ID == 106) return … Read more

How to save checkbox choice in wordpress

If I understood correctly, you are not able to save using update_post_meta. If this is you can try saving using jQuery using ajax, try this. //on change checkbox jQuery.ajax({ type: ‘POST’, url: “/wp-admin/admin-ajax.php?action=your_custom_function”, data:{ meta_id: ‘YOUR_META_ID’, //get user or post meta and set here meta_value: ‘YOUR_META_VALUE’ /the value you want to save in the meta … Read more