Brandon Kraft
Forum Replies Created
-
Thanks for the information. There’s a couple of things happening here.
Somewhere in the process by something on the site,
widget_textis being set to null, which is unexpected. Jetpack’s Image CDN filters thewidget_text(andthe_contentand some other things) to convert image URLs to our CDN.While those values should be strings (regular text), there isn’t a safety guard in Jetpack’s CDN code to confirm that before proceeding.
We fire up WordPress’ built-in HTML Tag Processor which doesn’t verify that the passed value to fire it up is a string, but is limits itself to returning a string after modification. Since the passed value is null, and not a string, it carries along fine until the return, which throws the fatal error.
Within Jetpack, we’re patching to add a safeguard via https://github.com/Automattic/jetpack/pull/44874 and I’ve proposed a fix to WordPress itself to also prevent the fatal from occurring ( https://core.trac.wordpress.org/ticket/63854 ).
All that said, it’s curious why/how that is being set to null in the first place, since, generally, code being passed through
widget_textfilters should be able to expect a string. Always good to safeguard, but it suggests something else in the stack is doing something unexpected.Thanks for opening the GitHub issue. I’ll have the engineering teams take a closer look at it.
For the error you passed along, it seems that something may be conflicting with
the_contentvalue that is passed between various plugins. The error is stating that Jetpack’s CDN is takingthe_contentand starting a HTML processor from WordPress itself…but the value ofthe_contentis null, which WordPress isn’t expecting.I opened an issue and sent up a patch to WordPress to address not throwing a fatal error when that happens ( https://core.trac.wordpress.org/ticket/63854 ), though, I am not sure where the
nullvalue is coming from.Forum: Reviews
In reply to: [Secure Custom Fields] This is stolen codeHello— did you attempt to use the plugin and found issues with it, or a statement regarding the overall context?
Forum: Reviews
In reply to: [Secure Custom Fields] Stolen plugin get what it deserves – 0/5Howdy @vertopolkalf!
Did you experience any problems using SCF or other friction that made the experience poor?
Forum: Plugins
In reply to: [Secure Custom Fields] Image Crashes PostAre there any error messages on the screen, in your browser’s console, or in your site’s error log that occurs when the crash happens? I don’t have a copy of Divi at the moment to attempt to test it, but curious if there are any errors that can direct me to where things may be amiss.
Thanks!
Forum: Plugins
In reply to: [Secure Custom Fields] Bug in “Select date” fieldCould you share some more details about what you’re seeing?
I tried setting up a new field group associated with the Posts post type with those three fields. On a new post in the block editor, using the meta fields at the bottom of the page, I’m able to use all three fields. Saving the post and reloading the editor retains the values.
I’m curious if you’re setup in a different way that would help me figure out what’s happening for you. While I don’t immediately recall anything in beta 7 that would be impacting this, can you try after updating to today’s beta 7?
Forum: Plugins
In reply to: [Secure Custom Fields] Images won’t show using SCFI’m having trouble duplicating this.
Here’s what I’m doing:
- New field group that is set to display with the Post post type.
- Image field with image field output, setting field name to
image_field - On a post, adding an image via the media selector.
- Via PHP, set to output
var_dump(get_field('image_field'));within the loop on a post. - View the page.
Doing that, I’m seeing the image field’s array dumped to the browser.
Is there something different that you’re doing that might help me figure out what’s happening for you and/or could you share how you’re setting things up?
While I don’t think anything that’s changed in beta 7 since beta 6 would impact it, please update to beta 7 just to be sure.
Thank you!
Forum: Plugins
In reply to: [Secure Custom Fields] Bug in “Select date” fieldThanks for the report. I’m investigating.
This should not be resolved in beta7 released today! Thank you!
Forum: Plugins
In reply to: [Secure Custom Fields] Dale limitHowdy!
This requires custom code at this time. If you’re not familiar with adding custom code, you can use a plugin like https://wordpress.org/plugins/code-snippets/ to add it.
You’d want to add this as a snippet that would be something like this. The default—and what you are running into–is it’ll allow years to be picked 100 years before or after the current year. The script below would change it to 1000 years before or after. You can change it to be more suitable to your needs.
/**
* Modifies the ACF date picker year range.
*
* @return void
*/
function scf_orgsupport_modify_acf_date_picker_year_range() {
// Only load if plugin is active.
if ( ! class_exists( 'ACF' ) ) {
return;
}
// Register and enqueue our custom script.
wp_register_script(
'scf_orgsupport_modify_acf_date_picker_year_range',
null,
array( 'acf-input' ),
null,
true
);
// Add inline script.
wp_add_inline_script(
'scf_orgsupport_modify_acf_date_picker_year_range',
'
acf.addFilter( "date_picker_args", function( args ) {
args.yearRange = "c-1000:c+1000";
return args;
});
'
);
// Enqueue the script.
wp_enqueue_script( 'scf_orgsupport_modify_acf_date_picker_year_range' );
}
add_action( 'wp_enqueue_scripts', 'scf_orgsupport_modify_acf_date_picker_year_range' );
add_action( 'admin_enqueue_scripts', 'scf_orgsupport_modify_acf_date_picker_year_range' );Forum: Plugins
In reply to: [Secure Custom Fields] After recent update option page has disappearedBeta 6 should resolve the issue; thanks for flagging it and apologies for the trouble!
Forum: Plugins
In reply to: [Secure Custom Fields] Cloning is corruptedThanks for flagging. Can you check out beta 6 to confirm it resolves what you’re seeing?
Forum: Plugins
In reply to: [Secure Custom Fields] Translation Bug in 6.4.1-beta4Thanks for the information. I believe this should now be fixed, notably with Russian being translated enough for WordPress.org to generate language packs. Can you upgrade to beta 5 and ensure your translation packs are up to date (on the same WordPress updates page) and let me know if you’re still having trouble?
Forum: Plugins
In reply to: [Secure Custom Fields] SCF Gallery field Translation errorI’m sending up beta 5 – can you check that out and see if it resolves it? If not, can you copy/paste the incorrect line and what it should be?
Forum: Plugins
In reply to: [Secure Custom Fields] SCF “Pro” fields?Can you give the development version a spin ( https://downloads.wordpress.org/plugin/secure-custom-fields.zip , also available from https://wordpress.org/plugins/secure-custom-fields/advanced/ ).
This works for me on Chrome and Firefox now. I’d like to confirm it fixes it up for you before pushing out a new beta version.