…trying not to become a man of success, but rather a man of value. (Albert E.)
My series plugin, that proved great so far, started to fail on me a bit after installing Wordpress 2.6, but this evening I found some fixes.
One of the bugs is that the administration menus don’t link correctly any longer.
Open orgSeries.php, and replace the function series_organize_options (line 156) with the following:
// ANDRIE
function series_organize_options() {
global $wp_version;
if (function_exists('add_options_page')) {
if ( isset( $wp_version ) && $wp_version >= 2.5 )
add_options_page('Organize Series Options', 'Series Options', 9, SERIES_DIR . '/' . 'orgSeries-options-new.php');
else
add_options_page('Organize Series Options', 'Series Options', 9, SERIES_DIR . '/' . 'orgSeries-options.php');
}
if (function_exists('add_management_page'))
add_management_page('Organize Series Management', 'Series', 9, SERIES_DIR . '/' . 'orgSeries-manage.php');
}
//END
Then there’s another bug related to Wordpress Revisions. If you have them turned off, then things are ok. Otherwise, the plugin starts counting revisions as well as part of the series, which ends up with numbering gone wrong.
Open series-taxonomy.php and replace line 384
$post_ID = (int) $post_ID;
with the following
$post_ID = (int) $post_ID;
// ANDRIE
$post = get_post($post_ID);
if ($post->post_type == 'revision'){
return;
}
//END
This fix doesn’t take care of the previous revisions though, that are already marked as part of the series. There is a fix for that as well, but that will be in an update to this post later this week ,)
Merely a living soul;
mostly one that survives.
Often seeing the best in people;
surely one that dies trying.
value, cherish, criticize, plan, enjoy, think
Darren
July 24th, 2008 at 11:35 pm
Hi Andrei,
thanks for working on some fixes for Organize Series - if the testing goes good and others find it works well I’ll use this fix and release a new version of OrgSeries.
One problem with the fix for revisions that I think I see right off the bat is that it eliminates the possiblity for users to change the order of an existing post in a series (or add it to a different series). Also, saving a new post to a series BUT with a different part number won’t work. Can you verify?
BTW - I’ll definitely credit you with the fix if I publish it
Andrei Neculau
July 25th, 2008 at 12:18 am
@Darren: in the meantime I turned my revisions-feature off (I simply get nothing out of it), but I did do all the things you mentioned I think.
Thing is that when you save an unpublished post..it’s not tagged with post_type=revision, so it does go through the numbering function. What I now see as a problem.. is.. when reverting to a revision, the series_part will not be there, I think..
I’ll see how it goes in the next few days.. and get back to you if everything is ok. Otherwise, I won’t
Josh
July 26th, 2008 at 11:39 am
Your code listings seem to contain some xml weirdness that causes problems. Try replacing the xml macros:
& -> &
> -> >
The front- and back-single-quotes also caused me some trouble.
Thanks for this update!
Josh
July 26th, 2008 at 11:40 am
@Josh: Let’s try that again:
& -> &
> -> >
etc.
(You get my current URL now, too!)
Andrei Neculau
July 26th, 2008 at 1:00 pm
@Josh: Thanks for the “bug-ticket”. It’s a problem with the syntax highlighter..
Ben M
July 31st, 2008 at 6:48 pm
Thank you for this and for the ‘Revision Deletion’ post. I was thinking that it was just the WP/Automattic people that were not pleasant, but my impression of the code isn’t what it was after all of this. What a headache. What’s wrong with keeping it simple?