Extended Body duplicated

Found a bug? Tell us!!
Post Reply
robnyl
Posts: 3
Joined: Tue May 28, 2013 12:52 am

Extended Body duplicated

Post by robnyl »

I recently upgraded from 1.6 to 1.7 and the process went well. The only issue I had was after the upgrade was completed upon my first load of the blog I got a server error that the script was not able to allocate enough memory. My PHP.INI had the memory limit set to 8MB so I bumped it up to 10MB. This appeared to solve the problem, however after browsing through the admin a bit more I noticed this error again toward the bottom of a screen. So I bumped it up to 12mb.

Now to my problem. This is a fairly new blog and the first few entries I did not use the "Extended Body" section when creating a blog entry. But now that I have a few more entries I decided to start using the Extended body feature. I edited each entry to highlight, cut, and paste from the Entry Body to the Extended Body. Saved and previewed. I noticed that it now appeared as those I never deleted the text from the entry body section. In other words, what I cut and pasted into the extended body was now showing twice in the preview and the public page. If I cut the text from the extended body and save the preview shows only the one paragraph in the body entry section as you would expect. So I tried pasting the cut block in both the entry and extended sections to see if it would be displayed 3 times. Thinking the extended section was just being duplicated, but no, it now looks just like you would expect with the contents of the entry and extended both showing only once.

Very strange.. I again attempted to format things the way I want them with a single paragraph in the body entry and the rest of the article in the extended entry section. But all the text of the extended entry displays twice when viewing the entire article. I put everything back into the body entry and saved until I get this figured out. BTW, I tested this with all three articles and attempted to create a new blog entry and all are having the exact same behavior.

I'm using the xcur template and other than that it's pretty much an out of the box installation.

Any ideas?
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Extended Body duplicated

Post by Timbalu »

robnyl wrote:I recently upgraded from 1.6 to 1.7 and the process went well. The only issue I had was after the upgrade was completed upon my first load of the blog I got a server error that the script was not able to allocate enough memory. My PHP.INI had the memory limit set to 8MB so I bumped it up to 10MB. This appeared to solve the problem, however after browsing through the admin a bit more I noticed this error again toward the bottom of a screen. So I bumped it up to 12mb.
Yes, some more memory limit can be also set via .htaccess (sometimes); eg

Code: Select all

php_value memory_limit "16M"
which is good to have.
robnyl wrote:Now to my problem. ...
I'm using the xcur template and other than that it's pretty much an out of the box installation.
Any ideas?
Sounds really strange. This should not happen. It may be that your xcur might be corrupted, somehow...
Please switch to 2k11 template once, to see if you still can reproduce this behaviour.
Also, did you install any further Plugins, which are...?
Is there a live view?
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
robnyl
Posts: 3
Joined: Tue May 28, 2013 12:52 am

Re: Extended Body duplicated

Post by robnyl »

My bad, live view is http://www.computerhotrod.com

Installed plug-ins are:

quick jump calendar v.1.1
Search for an entry version: 1.1
Browse archives by month version: 1.0
Shows the list of categories. version: 2.03
(LinkShare Ads) Holds a nugget of HTML in your sidebar version: 1.0 (recent add)
Shows RSS syndication links version: 1.4
Provides a link in the sidebar to your blog administration version: 1.0
Advertises the origins of your blog version: 1.0
Apply basic serendipity markup to entry text version: 1.3
Convert standard emoticons into graphic images version: 1.6
Convert newlines to BR tags version: 2.16
A variety of methods to prevent comment spam version: 1.80
[S]erendipity [P]lugin [A]ccess [R]epository [T]ool [A]nd [C]ustomization/nification [S]ystem - Allows you to download plugins from our online repository
version: 2.29

Most of these were part of the default installation if I recall correctly. I think I added the LinkShare Ads one and the Spam Prevention one.

I think you are correct. I switched themes and the problem was not there. Switched back to Xcur and boom it's broken.. home page looks great, but click on the link to read an entire article and the extended entry is presented twice. I'm going to leave it broken so you can see it until I have some time to dig into the template files and try to find the error.
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Extended Body duplicated

Post by Timbalu »

I can't see anything unusal here...
https://github.com/s9y/additional_theme ... es.tpl#L53
What I would correct, is the space between value= and following $entry... on line 65, but that should not be your issue: {assign var="weiter" value= $entry.title|truncate:30}.
Compare that file with yours, or copy the raw and put it onto your /axcur/entries.tpl.

Btw, the file name is axcur not xcur, while there is another template called xkur.

Edit: Sorry, I should have looked better:

Code: Select all

 {if $entry.is_extended}
<div class="serendipity_entry_extended"><a id="extended"></a>{$entry.extended}</div>
<div><a id="extended"></a>{$entry.extended}</div>
{/if}
These two lines in there are doubled. You have to decide, which one to use. I assume, the author wanted to test anything and added the second, which one I would recommend to purge.
I that was the right line, please give a feedback, so we can update the additional_template for others.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
robnyl
Posts: 3
Joined: Tue May 28, 2013 12:52 am

Re: Extended Body duplicated

Post by robnyl »

Thank you for doing the leg work for me, saved me a bunch of time for sure. I did the following;

Code: Select all

           {if $entry.is_extended}
               <div class="serendipity_entry_extended"><a id="extended"></a>{$entry.extended}</div>
<!--
               <div><a id="extended"></a>{$entry.extended}</div>
-->
            {/if}
Just commenting out the second DIV and that appears to have solved the problem.

Thanks again.
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Extended Body duplicated

Post by Timbalu »

Fine! ;-) I already updated the template. Will be available via Spartacus tomorrow.

Edit: Please delete this line since it is redundant and extended entry is written twice, even if the latter one is dsabled to show up, with your solution.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Post Reply