Forums / Setup & design /   being added after bold tag????

  being added after bold tag????

Author Message

Andy Boston

Monday 06 September 2010 6:50:45 am

We're implementing 4.3 on our new site and something strange is happening whereby is being added after some bold tags

<<span class="start-tag">b</span>>OAG SSIM File</<span class="end-tag">b</span>>
&<span class="entity">nbsp</span>

Anyone got any ideas as to why this would be happening???

Steven Bressey

Monday 06 September 2010 7:44:49 am

Hello Andy,

I noticed this problem on several sites we developped in 4.x and still haven't found a solution.

I also really need to remove the extra that is generated after every bold text, so if anyone has a solution, I would be very interested.

http://www.alma.fr

André R.

Tuesday 07 September 2010 3:05:27 am

Is this copy and paste from somewhere?

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Steven Bressey

Tuesday 07 September 2010 4:36:00 am

In my case, no it is not.

The text always comes from typing in ezoe and then I use ezoe formatting buttons.

http://www.alma.fr

Yannick Komotir

Tuesday 07 September 2010 6:09:14 am

Hi,

Which browser is used ? Can you try to override default strong.tpl by creating your own in your design ?

<|- Software Engineer @ eZ Publish developpers -|>
@ http://twitter.com/yannixk

Steven Bressey

Tuesday 07 September 2010 6:33:08 am

I get the same result when editing content wether I use Internet Explorer (7) or Firefox (3.5).

The " " doesn't come from strong.tpl but more likely from paragraph.tpl.

Here is what I get in the source code of the page with debug :

<span class="comment"><!-- START: including template: extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tpl (design:content/datatype/view/ezxmltags/paragraph.tpl) --></span>
<<span class="start-tag">p</span>>
<span class="comment"><!-- START: including template: design/standard/templates/content/datatype/view/ezxmltags/strong.tpl (design:content/datatype/view/ezxmltags/strong.tpl) --></span>
<<span class="start-tag">b</span>>Puis du gras</<span class="end-tag">b</span>>

<span class="comment"><!-- STOP: including template: design/standard/templates/content/datatype/view/ezxmltags/strong.tpl (design:content/datatype/view/ezxmltags/strong.tpl) --></span>
&<span class="entity">nbsp;</span>et juste après du texte normal.</<span class="end-tag">p</span>>

<span class="comment"><!-- STOP: including template: extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tpl (design:content/datatype/view/ezxmltags/paragraph.tpl) --></span>

<span class="comment"><!-- START: including template: extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tpl (design:content/datatype/view/ezxmltags/paragraph.tpl) --></span>
<<span class="start-tag">p</span>>&<span class="entity">nbsp;</span>Et 
<span class="comment"><!-- START: including template: design/standard/templates/content/datatype/view/ezxmltags/strong.tpl (design:content/datatype/view/ezxmltags/strong.tpl) --></span>
<<span class="start-tag">b</span>>alors</<span class="end-tag">b</span>>

I then had a look at the template file : extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tpl :

{set $classification = cond( and(is_set( $align ), $align ), concat( $classification, ' text-', $align ), $classification )}
<p{if $classification|trim} class="{$classification|wash}"{/if}>
{if eq( $content|trim(), '' )} {else}{$content}{/if}
</p>

The thing is, the $content variable is not empty as it contains some text ("et juste après du texte normal" ) , so I don't think the problem comes from this template but it is more likely "added/generated by eZpublish" at the beginning of the content when submitting changes. I noticed that sometimes you have to edit the content twice in order to get the " ".

I removed the test on $content in the template, so that the code became :

{set $classification = cond( and(is_set( $align ), $align ), concat( $classification, ' text-', $align ), $classification )}
<p{if $classification|trim} class="{$classification|wash}"{/if}>
{$content}
</p>

But the result is the same ...

I really think this comes from the kernel and/or ezoe, but the question is where ??

I already spent hours looking in the code but could not find it.

Edit : The eZ forum "literal text" generates some extra tags : span class="comment" so the source code you can see in this post is not exactly the same as the real one.

http://www.alma.fr