Nevertheless, in 3 of the 11 chapters (5, 8 and 9) nothing is shown, neither the table of contens nor the text itself (although text is sitll there, I can go and edit the post in admin area). Putting just the (withput the table code) does not solve the problem either.
If I remove the , the text is shown back again in post.
I have rechecked everything several times and nothing seems to be wrong…
As the are lengthy chapters, I have made a test splitting in two, one of this problematic chapters (specifically number 9)… and then the splitted articles are shown correctly.
My question is: could th lenght of the chapters be the problem?
Thanks in advance for your answer.
2:36 pm December 23, 2009
Ade
Admin
posts 1140
2
Post edited 2:38 pm – December 23, 2009 by Ade
Hi Javier,
Glad you like the plugin.
There seem to be a few problems with the layout (looking at your site in FF3).
Firstly, have you made any changes to any of the plugin code? By default, it should output the list in ul tags, not ol tags.
Secondly, I wouldn't use a table. I would place the shortcode at the top of your post content. The plugin automatically wraps the output in a div with an id="name of serial", therefore add a suitable style to style.css, say this:
Obviously, replace serial-name with the actual ID name generated by the plugin. Actually, I've just realised that this can be buggy because ID names cannot contain characters other than alphanumeric and hyphens*. Therefore, I would change the Serial name (ie the custom field value you are assigning to each post) to a simple single word or multiple words with no punctuation – eg no commas, full-stops, @#!_ etc.
This CSS should place the contents list in the correct place on the page.
Title length shouldn't be a problem.
* Since you have highlighted a bug to me (thank you), I'm going to update the plugin in the next hour or so to fix this.
Once you have done this (you don't need to wait for the plugin update), post back and I'll take another look.
I did two very small and esay changes in the code:
1. <ol> instead of <ul>
2. add <br> between pre-text, title and post-text, to format it in different lines.
Re the css formatting, two things:
1. First, as you said, internationalization: á ñ, etc…
2. Second: a style for every different id could be very time-consuming… it would be better to asign one style to every id…
Thanks again. I wait for your reply
5:49 pm December 23, 2009
Ade
Admin
posts 1140
4
Post edited 6:08 pm – December 23, 2009 by Ade
Yes, the more I think about, the more I think I've tried to be too clever – but haven't taken into account all the possible characters used in a Serial Name. So, I'm tempted to just hardcode the div id to "serial-posts" and forget about dynamically naming the CSS id name.
I'm going to think about an alternative solution, but in the meantime, if you want to do this yourself, you can change the following lines of code in serial-public-core.php (assuming you're using version 1.1):
Find this:
/* Replace whitespace to use Serial Name as CSS class name */ $serial_name_css = str_replace( " ", "-", $serial_name );
and change it to this:
/* Div ID name */ $serial_name_css = 'serial-posts-wrapper';
I have tried to change the "name" of the Serial personalized field, but it doesn't solve the problem either.
I rechecked no duplicities in Serial field, no one is there.
I also checked in different browers, the same in all of them: Firefox, Explorer, Chrome.
If you go to http://www.vicencianos.org/web…..-un-santo/ (first chapter) you will see it displayed correctly, the list with the 11 chapters. If you ckick there to "capitulo 1" it will work also, an so in "Capitulo 2". But if you click in the rest of the chapters, you will get a "blank" page…. no list, no contens.
Thank you again for your time and efforts.
8:45 pm December 23, 2009
Ade
Admin
posts 1140
12
No problem! I'm as curious as you to find the cause of this. I'm quite puzzled because I cannot reproduce this problem here. I have many posts assigned to one Serial and the list shows correctly on each post.
Can you temporarily change the plugin's Settings and uncheck the "Include current post" box? I want to see if that makes a difference.
The next thing to try is to disable your other plugins, just in case there is a conflict.
Unckeck… and still the same. In fact, I have tried every possible combination, with no luck.
I have deactivated all the plugins in the web except Serial Posts plugin… still the same. I will keep all the plugins deactivated, for you to see, until next post…
Thanks again… this is really puzzling.
9:09 pm December 23, 2009
Ade
Admin
posts 1140
14
The only other thing I can suggest is that you send me an admin login and password by PM so that I can take a look.
I took a look at Admin and everything seems to be set up correctly. I didn't want to play around too much in case I undid something important!
Considering you've got Super Cache installed, your site seems slow to me. I also got a 500 Internal Server Error at one point just navigating around your site. I wonder if your server is maxing out on PHP memory or CPU?
YARPP uses a lot of memory resources (I try to avoid using it, because of that), so it would be interesting to see what happens when that and Super Cache are disabled. You could also install WP-Tuner plugin to get some information on database queries, PHP memory and CPU usage.
The problem is that I can't reproduce your problem on my test install. I am sure the problem lies elsewhere and that Serial Posts is working properly, but something else is causing teh problem. There's only so much I can do at my end.
I am really grateful for your patience and support…
It is true that my host has memory issues from time to time. I think I will be moving to another server, dedicated this time. The only problem is moving 10+ gigs of data…
Anyway, I really liked your plugin and will tell you about my success (or problems) when I move everything.
Thanks again, and merry Christmas.
1:17 am December 25, 2009
Ade
Admin
posts 1140
17
Javier,
I think I've found the problem – and the fix.
There is a bug in WordPress that prevents shortcodes working properly when a post exceeds 100k characters. You can read about it here, and it's still not fixed in WP 2.9:
The symptom of the bug is that you get an empty post.
You are using the serialposts shortcode and your chapters are long (by WP post norms), so I'm sure this bug is causing the problems on your site.
There are two fixes to get around this (take your pick)….
1. Stop using the shortcode in your book chapter posts and use the template tag instead, therefore in index.php (or single.php, whichever is used for the single post view) add this:
<?php serial_posts(); ?>
Add this immediately above the call to the_content in the relevant template file.
2. Alternatively, add this code to your wp-config.php immediately above the Happy Blogging line:
ini_set('pcre.backtrack_limit', 1000000);
Be aware, fix #2 will only work if your server is running PHP 5.2+.
Man, you are good! I was almost sure it was an issue with the lenght of the posts, but I didn't think in a bug in WordPress core.
The workaround in config.php worked like a charm.
May I suggest you to put this issue in instructions.txt as a warning…
Are you planning in implementing the suggestions I have given you in the other entry?
Thanks.
11:39 am December 25, 2009
Ade
Admin
posts 1140
19
Glad it worked!
Good idea about adding it to the FAQ/Instructions. Thanks.
As for your suggestions on the other thread – yes, I'm thinking about it. Personally, I try to avoid custom fields as much as possible because it's something else for the ordinary user to have to remember – and non-technical users seem to struggle with custom fields. I'm going to see if I can give this extra functionality without using additional custom fields.
Developing plugins for the community represents a considerable investment of my time and energy. If you have found these plugins useful, please consider making a donation to help support future development. Your support will be much appreciated. Thank you!