Fix for Mystique under PHP 8.1
-
In case anyone is still using this theme and wants it to work under PHP 8.x, the widget class constructor needs to be updated (generated by ChatGPT 4.0):
// function Mystique_Widget() { - not PHP 8.0 compat function __construct() { /* Widget settings. */ $widget_ops = array( 'classname' => 'mystique', 'description' => __( 'Displays your categories, tags, most commented posts and recent comments in a tabbed interface.', 'mystique' ) ); /* Widget control settings. */ $control_ops = array( 'width' => 300, 'height' => 350, 'id_base' => 'mystique-widget' ); /* Create the widget. */ // Old code not PHP 8.0 Compat - $this->WP_Widget( 'mystique-widget', __( 'Mystique Tabbed Widget', 'mystique' ), $widget_ops, $control_ops ); parent::__construct( 'mystique-widget', __( 'Mystique Tabbed Widget', 'mystique' ), $widget_ops, $control_ops ); }
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Fix for Mystique under PHP 8.1’ is closed to new replies.