There might be a better solution, but these changes fixed it for me.
Line 11
class dynWid {
private $dbtable;
public $device;
public $hostname;
public $dwoptions = array();
public $dynwid_list;
public $enabled;
private $firstmessage = TRUE;
public $ip_address;
public $listmade = FALSE;
public $overrule_maintype = array();
private $registered_sidebars;
public $registered_widget_controls;
public $registered_widgets;
public $removelist = array();
public $sidebars;
public $template;
public $url;
public $plugin_url;
public $useragent;
public $userrole;
public $whereami;
private $wpdb;
public $wpml;
public $custom_taxonomy;
Line 67
/**
* dynWid::__get() Overload get
*
* @param string $name
* @return mixed
*/
public function __get($name) {
if(property_exists($this, $name)) {
return $this->$name;
} else {
return null;
}
}
Line 95
/**
* dynWid::__set() Overload set
*
* @param string $name
* @param mixed $value
*/
public function __set($name, $value) {
if(property_exists($this, $name)) {
$this->$name = $value;
} else {
}
}
@wendihihihi
Can you share the minimum set of dynamic widget edit options that lead to this behavior? We have tested on PHP 8 and with WP 6.4 and can’t reproduce this error.
Thanks for your code change suggestions. If we can get some step-to-reproduce, that will make it straightforward to incorporate your fix!
Did you test it also for php 8.2?
If you only test it on php8 you won’t get the errors. I also won’t get them in php 8.1.
Also, make sure in wp-config.php set the debug to true
define( 'WP_DEBUG', true );
-
This reply was modified 2 years, 4 months ago by
Wendihihihi.
Hi,
Thanks for your patience and suggested solution. We’ve rolled out the fix for the “Creation of dynamic property” warning in 1.6.3, please update and let us know if you have any further issues.
Thanks,
Alex