WordPress.org

Ready to get started?Download WordPress

Forums

Genesis Co-Authors Plus
[resolved] Stripslashes Error (8 posts)

  1. Tisha Oehmen
    Member
    Posted 1 year ago #

    Using the base Genesis Framework, and only 2 plugins -- this one and Co-Authors Plus, I receive the following error when I add more than one author to the post and update the post. (the stripslash error appears a number of times on the same screen, but for the sake of brevity, I've only copied it here once.)

    Warning: stripslashes() expects parameter 1 to be string, array given in /home/content/***/wp-content/themes/genesis/lib/functions/options.php on line 286
    
    Warning: Cannot modify header information - headers already sent by (output started at /home/content/***/wp-content/themes/genesis/lib/functions/options.php:286) in /home/content/***/wp-includes/pluggable.php on line 876

    On the front end of the site, the first author's profile is displayed repeatedly, instead of one for each author.

    Has anyone successfully resolved this problem?

    http://wordpress.org/extend/plugins/genesis-co-authors-plus/

  2. Pete Kloehn
    Member
    Posted 1 year ago #

    I just ran into the same issue. Any update on this?

  3. benfurfie
    Member
    Posted 1 year ago #

    I ran into the same problem as you guys.

    It took a lot of digging, but I eventually found this:

    http://www.hongkiat.com/blog/wordpress-error-warning-cannot-modify-header-information/

    It appears that one of the plugins adds an additional space at the bottom of the wp-config file that causes the stripslash error.

    Following those instructions should resolve it.

  4. Pete Kloehn
    Member
    Posted 1 year ago #

    That didn't resolve my issue. There were no leading spaces in my wp-config.php file and the close tag on that file was removed 5 years ago.

    Running through the list of files associated with this error also didn't result in finding any leading/trailing spaces.

    There were extra spaces in the plugin PHP file, but didn't resolve the issue either.

    Maybe the string the plugin passes is concatenated/malformed and that's causing Genesis or the core to choke on it?

  5. jeangalea
    Member
    Plugin Author

    Posted 1 year ago #

    I don't really know what's wrong here guys, and I'm extremely busy right now so it won't be easy to dig deeper. Having said that, if there's anyone else who can supply a fix, this code is on GitHub so once a patch is supplied I'll release an update here.
    https://github.com/jgalea/genesis-coauthors-plus

  6. benfurfie
    Member
    Posted 1 year ago #

    I had a look through the code and couldn't see anything that would obviously be triggering off the stripslash errors.

    It appears that the error is being caused by the function that Genesis uses to remove the slashes from numerical HTML entities when they're being rendered – namely wp_kses_decode_entities.

    When I removed the Genesis Co-Authors Plugin, the stripslash errors remained. However removing the Co-Authors plugin itself removes the stripslash error.

    That makes me thing the issue is in the Co-Authors Plugin itself rather than the Genesis plugin.

    My knowledge of php isn't great, but I guess you'd need to include a function that unhooks wp_kses_decode_entities when dealing with Co-Authors in Genesis in order to prevent the stripslash error.

    If that's in the right direction, let me know and I'll keep digging.

  7. CircleReader
    Member
    Posted 1 year ago #

    Looks like the same problem occurs with Co-Authors Plus (http://wordpress.org/plugins/co-authors-plus/) whether or not you have the Genesis author-box support plugin enabled.

  8. jeangalea
    Member
    Plugin Author

    Posted 12 months ago #

    Seems like the issue is not directly related to this plugin then.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic