jasontremblay
Forum Replies Created
-
I was getting the same error, and looked over the docs for the function
wp_use_widgets_block_editor()
… the code says this function was added in WP version 5.8.0.So if a site isn’t updated to WP 5.8 yet, then this function (that Feedzy is using) would be undefined, resulting in a fatal error.
Confirmed: updating the site to WP 5.8 resolved the error on my site.
Forum: Plugins
In reply to: [SVG Support] localize error with WordPress 5.7Passing arrays to wp_localize_script() does remove the PHP notice (since wp_localize_script is expecting an array for the third argument), but then the passed data isn’t in the format the
svgs-inline.js
script expects.The message in the error log suggested using the wp_add_inline_script() function instead. This worked for me to remove the errors (replaces lines 144 and 145 of
svg-support/functions/enqueue.php
):wp_add_inline_script( 'bodhi_svg_inline', sprintf( 'cssTarget=%s;ForceInlineSVGActive=%s;', json_encode($css_target_array), json_encode($force_inline_svg_active) ) );
- This reply was modified 3 years, 9 months ago by jasontremblay.
Forum: Plugins
In reply to: [Root Relative URLs] Blacklist URLs not workingI had the same problem. I expected blacklisted URLs to be excluded when urls are being rewritten to root-relative.
I tried the solution proposed by @eric-o, but it didn’t work for me. I ended up hacking t he plugin by adding this to the
proper_root_relative_url
function:$blacklist_urls = split("\n", get_option('emc2_blacklist_urls')); foreach ($blacklist_urls as $x) { if (stripos($url, $x) !== false) { self::$massage = true; return $url; } }
Actually, I wasn’t explaining how to add any code. I was saying it’s a problem with WordPress core. You may be able to search your theme’s code for “is_home” and find a way to work around/remove that.
…unless yours is a different problem with the same symptoms, which is always a possibility.
I was also having this problem. Did some digging and found that it was because my theme was filtering the request, as documented on this page:
https://codex.www.ads-software.com/Plugin_API/Filter_Reference/request
In the example there, we create a dummy query, and then check it’s “is_home” property. I assume “is_home” should be true only for the blog home page, however it seems to be true for the “events” query too.
Extra explanation…
In the WordPress core, in wp-includes/query.php, line 1605-1606, it’s basically assuming that if other conditions aren’t met (i.e. is_singular, is_archive, etc) then “is_home” should be true. That seems like a round-about way of setting is_home, but I don’t know the intention behind it, so I can’t really say for sure.
Yep, I’m also seeing this problem.
Forum: Fixing WordPress
In reply to: users missing from author dropdown after upgrade@nickyboy, sorry I’ve never used the Quick Edit, so I’m not familiar with that code.
Forum: Fixing WordPress
In reply to: users missing from author dropdown after upgrade@scottbothel… you also need to add this line to the beginning of the theme_post_author_override function I posted above:
global $post, $user_ID;
Forum: Fixing WordPress
In reply to: users missing from author dropdown after upgradeI decided it was impractical to try to solve this through the admin… who knows if the problem would recur for every blog I add, and I’d have annoying busy work to do over and over. Instead, I just added a filter to my functions.php to include all users (not just Authors).
// Filter to fix the Post Author Dropdown add_filter('wp_dropdown_users', 'theme_post_author_override'); function theme_post_author_override($output) { // return if this isn't the theme author override dropdown if (!preg_match('/post_author_override/', $output)) return $output; // return if we've already replaced the list (end recursion) if (preg_match ('/post_author_override_replaced/', $output)) return $output; // replacement call to wp_dropdown_users $output = wp_dropdown_users(array( 'echo' => 0, 'name' => 'post_author_override_replaced', 'selected' => empty($post->ID) ? $user_ID : $post->post_author, 'include_selected' => true )); // put the original name back $output = preg_replace('/post_author_override_replaced/', 'post_author_override', $output); return $output; }
Forum: Fixing WordPress
In reply to: users missing from author dropdown after upgradeI’m having the same problem. Same set of users, same roles. They all appear in the drop-down on one of my multisite blogs, but most are missing from the other. Anyone have any insight into this?
Forum: Fixing WordPress
In reply to: HTTP Error on image upload – STILLIf you’re using WPMU, you may be getting this error because of the “fileupload_maxk” setting in the “wp_sitemeta” table.
Ok, if you’re uploading big files, you may have changed the PHP ini settings so that you can upload files larger than the PHP default of 2MB — as discussed here. However, it seems that WPMU enforces it’s own separate file upload size limit. When using the browser uploader, you’ll get an error that says:
“This file is too big. Files must be less than 1500 Kb in size.”
But if you use the flash uploader, you get the dreaded “HTTP Error”.
Increasing the “fileupload_maxk” as detailed in this article made both errors go away for me ??
Forum: Plugins
In reply to: jQuery 1.4.*, Contact Form 7 v2.2.2 and JSON (and Tracking with Analytics)Thank you SO much for posting this! My form’s ajax has been silently failing for hours and I didn’t even think to check for valid AJAX return values. Viola indeed ??
Forum: Themes and Templates
In reply to: Filter post list with a custom field.I’m really interested in doing something similar. Anyone out there have any suggestions?