[SOLVED] CMSMS 1.8: An error occurred parsing content blocks

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Locked
ilia3d

[SOLVED] CMSMS 1.8: An error occurred parsing content blocks

Post by ilia3d »

after upgrade 1.7.1 -> 1.8 can't  open any page in backend... here is error message "An error occurred parsing content blocks (perhaps duplicated block names)"
please heelp :-\

[Solved]
scooper, NaN and owr_web - thanks a lot for help!  :)
Last edited by ilia3d on Sun Jul 11, 2010 12:52 pm, edited 1 time in total.
NaN

Re: CMSMS 1.8: An error occurred parsing content blocks (perhaps duplicated block...

Post by NaN »

Take a look in your template and check the {content... } tags.
How often are they used and what params are used?

E.g:

Code: Select all


{content}
{content}

Would cause this error.

Also:

Code: Select all


{content block="block1"}
{content block="block1"}

or even just

Code: Select all


{content block="title"}

since "title" is a default content property that cannot be used as a content block.
ilia3d

Re: CMSMS 1.8: An error occurred parsing content blocks (perhaps duplicated block...

Post by ilia3d »

Take a look in your template and check the {content... } tags.
How often are they used and what params are used?
first use

Code: Select all

<head>

{capture assign='captured_content'}{content}{/capture}

{if isset($detail_title)}
<title>{sitename} :: {$detail_title}</title>
{else}
<title>{sitename} :: {title}</title>
{/if}
second

Code: Select all

{if isset($detail_title)}
<h1>{$detail_title}</h1>
{else}
<h1>{title} {$detail_title}</h1>
{/if}

{content}
i changed to  {content block="title"} or {content block="block1"}
but seems not to be working.. :(
scooper
Forum Members
Forum Members
Posts: 242
Joined: Fri Dec 09, 2005 12:36 pm

Re: CMSMS 1.8: An error occurred parsing content blocks (perhaps duplicated block...

Post by scooper »

I've just come across this problem as well in a template where I have a conditional (to check for logged in users) which uses the {content} in two places.

Assigning the content to a new smarty variable as you seem to be doing works for me.

So doing something like:

{capture assign='captured_content'}{content}{/capture}

and then using {$captured_content} in the conditionals in my template where I had previous been using the {content} tag.
owr_bgld

Re: CMSMS 1.8: An error occurred parsing content blocks (perhaps duplicated block...

Post by owr_bgld »

ilia3d wrote:

Code: Select all

<head>

{capture assign='captured_content'}{content}{/capture}

{if isset($detail_title)}
<title>{sitename} :: {$detail_title}</title>
{else}
<title>{sitename} :: {title}</title>
{/if}
In this code you call {content} first time (you capture it to the variable $captured_content)
ilia3d wrote:

Code: Select all

{if isset($detail_title)}
<h1>{$detail_title}</h1>
{else}
<h1>{title} {$detail_title}</h1>
{/if}

{content}
Here you have the {content} the second time, this you have to change to

Code: Select all

{if isset($detail_title)}
<h1>{$detail_title}</h1>
{else}
<h1>{title} {$detail_title}</h1>
{/if}

{$captured_content}
Deak

Re: [SOLVED] CMSMS 1.8: An error occurred parsing content blocks

Post by Deak »

Bah to code-breaking changes. This got me as well.  >:(
Locked

Return to “CMSMS Core”