[resolved] Fix for WPlite v1.3 when using WP 2.6-beta3 (5 posts)

  1. Steven
    Posted 8 years ago #

    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'));


    $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.



  2. Steven
    Posted 8 years ago #

    Fixed in version 1.3.1 :) Thanks!

  3. introspectif
    Posted 7 years ago #

    Hey stgoos. I just got to read this. Thanks for posting about it!

  4. emaster
    Posted 7 years ago #

    Is this plugin compatible with wp 2.7? This is such a useful plugin to get rid of that ridiculous dashboard.


  5. ktdreyer
    Posted 7 years ago #

    Unfortunately I got an infinite redirect error when I disabled the dashboard in 2.7.0. I'm using WPLite 1.3.1. It seems to work when disabling "posts" or "comments", just don't disable the dashboard (yet :-)

Topic Closed

This topic has been closed to new replies.

About this Topic