WordPress.org

Ready to get started?Download WordPress

Forums

Calendar Posts
warning when saving post (8 posts)

  1. alroe
    Member
    Posted 3 years ago #

    The plugin seems simple and elegangt, but I get a warning when saving post after having chosen dates in Calender:

    Warning: sort() expects parameter 2 to be long, string given in /home/xx/wp-content/plugins/calendar-posts/calendar-posts.php on line 138

    Warning: sort() expects parameter 2 to be long, string given in /home/xx/wp-content/plugins/calendar-posts/calendar-posts.php on line 138

    Warning: Cannot modify header information - headers already sent by (output started at /home/xx/wp-content/plugins/calendar-posts/calendar-posts.php:138) in /home/xx/wp-includes/pluggable.php on line 897

    Theme suffusion
    Other plugins installed: alphabetical list, list category posts, restricted site access

    http://wordpress.org/extend/plugins/calendar-posts/

  2. zowieguy
    Member
    Posted 3 years ago #

    I am getting the same error with this plugin when publishing post:

    Warning: sort() expects parameter 2 to be long, string given in /home3/xxxxx/public_html/wp-content/plugins/calendar-posts/calendar-posts.php on line 138

    Warning: sort() expects parameter 2 to be long, string given in /home3/xxxxx/public_html/wp-content/plugins/calendar-posts/calendar-posts.php on line 138

    Warning: Cannot modify header information - headers already sent by (output started at /home3/xxxxx/public_html/wp-content/plugins/calendar-posts/calendar-posts.php:138) in /home3/xxxxx/public_html/wp-includes/pluggable.php on line 897

    Any idea how to fix this because this plugin is just what i was looking for.
    Thanks'

    http://wordpress.org/extend/plugins/calendar-posts/

  3. zowieguy
    Member
    Posted 3 years ago #

    Still No Solution...

    I was using three different plugins to accomplish an "event" site.

    1. Calendar Posts
    2. The Future is Now
    3. AJAX Calendar Future POSTS

    First off.. I realized that I didn't need "AJAX Calendar Future POSTS" because is was kinda redundant with the "The Future is Now" plugin. The stock WP Calendar will show future posts with "The Future is Now" (I wasn't sure if it would at first, but it does).

    So, with that out of the way... I can create a future post without any error if I just change the post date and do not touch the "Calendar Posts" calendar. But, it will not show in the CP widget.

    If I then go back to edit post and try to use the CP calendar, i get the same error when updating.

    I will keep trying to figure this out.

  4. zowieguy
    Member
    Posted 3 years ago #

    Well it seems that even though I am still getting the error, the post is published anyways.
    It's kind of a pain going around the error.... but as long as the post is there i guess I can deal with it until it gets fixed.

    Here is the site I am working on: http://www.concretestreet.net/

    Cheers'

  5. swedish boy
    Member
    Plugin Author

    Posted 3 years ago #

    Thanks for the feedback.
    I will fix this in the next update.
    This is reproduced because of faulty set SORT_NUMERIC, constant. I have set it as a string by misstake. If you want a fix already now you can search the file for SORT_NUMERIC and remove the quotes on row 138.

    sort($datum_a, 'SORT_NUMERIC');
    
    // should be changed to
    
    sort($datum_a, SORT_NUMERIC);

    Cheers

  6. zowieguy
    Member
    Posted 3 years ago #

    Fantastic.. worked like a charm.

    Thanks' Swedish..

    Cheers'

  7. ReneeRox
    Member
    Posted 2 years ago #

    This still seems to be an issue. I will try the fix error that you mentioned.

  8. ReneeRox
    Member
    Posted 2 years ago #

    Ok, the fix worked. thanks!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic