| |
@@ -1,8 +1,12 @@
|
| |
<?php
|
| |
class magazine_postseries_widget extends WP_Widget {
|
| |
|
| |
- function magazine_postseries_widget() {
|
| |
- parent::WP_Widget(false, $name = 'Magazine postseries widget', array('description' => __('Displays postseries.', 'rowling') ));
|
| |
+ function __construct() {
|
| |
+ $widget_ops = array(
|
| |
+ 'classname' => 'magazine_postseries_widget',
|
| |
+ 'description' => 'Displays postseries.'
|
| |
+ );
|
| |
+ parent::__construct( 'magazine_postseries_widget', 'Magazine postseries widget', $widget_ops );
|
| |
}
|
| |
|
| |
function widget($args, $instance) {
|
| |
This way of building a widget was broken when upgraded to php 8, and is deprecated since WP 4.3
See https://discussion.fedoraproject.org/t/upgrade-of-the-blog-to-php-8-0-and-wp-6-0/39618
and https://wordpress.org/support/topic/wp-5-6-rc4-php-8-0-uncaught-argumentcounterror/#post-13755072