Fix for WPlite v1.3 when using WP 2.6-beta3
-
It looks like get_option() has changed in WP2.6 (haven’t checked this out though), so as a result you get lots of Warning: unserialize() expects parameter 1 to be string… error messages when you use WPlite v1.3.
To fix this you need to look at the use of the PHP unserialize() function which can be found in wplite.php on lines 55, 56, 82, 154, 155, 156, 157, and 245. You simply have to remove it ??
So, for example, line 55 would turn from:
$disabled_menu_items = unserialize(get_option('wplite_disabled_menu_items'));
into:
$disabled_menu_items = get_option('wplite_disabled_menu_items');
Suggestion for WPlite v1.4: create an extra function to which you sent the required get_option() data and in which you check the WP version in use. If it’s WP 2.6+ then you can return the input 1:1 and when it’s WP 2.5 or lower then you will use the unserialize() funtion.
Cheers!
- The topic ‘Fix for WPlite v1.3 when using WP 2.6-beta3’ is closed to new replies.