Displaying recent posts on static page with template-part via shortcode
Displaying recent posts on static page with template-part via shortcode
Displaying recent posts on static page with template-part via shortcode
Using your comments, I found what I was missing. I initialized my textdomain with : add_action(‘admin_init’, ‘related_post_shortcode_init’); function related_post_shortcode_init() { load_plugin_textdomain(‘related-post-shortcode’, false, basename( dirname( __FILE__ ) ) . ‘/i18n’ ); } So, the textdomain was ok and ready for back-office translations (admin_init), but not for front, as @Mark Kaplun suggested. I simply added another hook … Read more
I’ve found a wordaround that “solves” the problem, but I’m not going to accept this as an answer until I’m not sure it is the only solution (which I suspect it is not). I can tell WP is not including the Ultimate VC Addons (UVCA from now on) CSS because my page does not contain … Read more
Shortcode: text content ends up outside html tags
wp_reset_postdata() and wp_reset_query() inside shortcode are not working to reset original page query
I have a working solution that uses Promises, but it is ugly and I would certainly appreciate tips. I haven’t been able to figure out how tot instantiate a subclass of promises, so the code is repetitive and inefficient, and also instantiates the wp.media frame twice. In addition, there’s no “reject” directive in the Promise … Read more
WordPress TinyMCE : Get value of popup button
This could be due to the do_shortcode running through wpautop, see here for details on disabling that: https://stackoverflow.com/questions/5940854/disable-automatic-formatting-inside-wordpress-shortcodes But as frogg3862 said, what you need to do instead of that is to just trim out the beginning and ending whitespace from $content to prevent the non-breaking space from being automatically added. function infoButton($atts, $content = … Read more
Gradient and boxshadow are fine to put inline. Your trouble will be with the hover states. Luckily there is a trick. You can put the hover styles in an outer element and force inherit on hover. Like this: <div class=”myshortcode”> <a style=”color:blue;”><span style=”color:red;”>Content</span></a> </div> In your style.css you add this generic line with a transition … Read more
Found a solution. Adding this code below to the functions.php file of your theme will do the trick. if ( ! isset( $content_width ) ) $content_width = YOUR WIDTH HERE;