certain code into content box will break SF

Posted by Community Admin on 04-Aug-2018 15:53

certain code into content box will break SF

All Replies

Posted by Community Admin on 19-Jan-2011 00:00

Hi!

It seems that if one adds a content block into template (or perhaps just to the page), then goes to edit the block.. and writes something like the following:

<p style="width:12px> &nbsp </p>

if saved, this is irreversible error.. as there are no more edit buttons on any of the blocks (any "edit" and "more" buttons do not come up, although you are able to see that there would be edit-link there if you hover over it with the mouse) on the page. In fact, you can't even drag any widgets or layout controls.

If there are other templates that are based on template that has this kind of mistake, they will suffer the same fate - ie they can't be edited. Nor can any pages that are based a) on the broken template or b) on template that has the broken template as ancestor at some point of the tree of base templates.

There is one error reported, when the page is accessed with Chrome:

Telerik.Web.UI.WebResource.axd:14057Uncaught TypeError: Cannot call method 'setAttribute' of undefined

Firefox on the other hand reports the following error:

Error: this._middleRightBar is undefined
Source File: localhost:367/.../Telerik.Web.UI.WebResource.axd
Line: 14057

Not sure if this is more a bug on the radeditor or SF.. but if it's radeditor's bug (for allowing such broken code to be saved and not fixing it to some extent - like adding extra " character before next > character if there is uneven number of them inside a tag), then SF still (in my opinion) has a bug that it doesn't allow the user to go back to edit to correct the mistake. 

Workaround is to manually find the html from the sql server.. or to redo the whole page. Of course, latter isn't always an option (for example if the template is base template to some other template that is used heavily.. everything would disappear from the ones that were based on that template).

This is with the version 4.0.1098.0 of the SF.

P.S. below is what code will be the result when one returns to the page.. the style continues from line 28 until line 33.. in a way never catching the end tag for the block which has that broken style.

01.<table class="rdTable">
02.   <tr class="rdTop">
03.      <td class="rdLeft"> </td>
04.      <td class="rdCenter">
05.         <div id="ctl11_C_ctl07_T" class="rdTitleBar zeControlTitlebar">
06.            <em>Content block</em>
07.            <ul class="rdCommands">
08.               <li>
09.                  <a title="Edit">
10.                     <span class="rdEditCommand"> </span>
11.                  </a>
12.               </li>
13.               <li>
14.                  <a title="More">
15.                     <span class="rdMoreCommand"> </span>
16.                  </a>
17.               </li>
18.            </ul>
19.         </div>
20.      </td>
21.      <td class="rdRight"> </td>
22.    </tr>
23.   <tr class="rdMiddle">
24.      <td class="rdLeft"> </td>
25.      <td class="rdCenter">
26.         <div id="ctl11_C_ctl07_C" class="rdContent" perm_delete="True" perm_indexchanged="True" perm_edit="True" perm_duplicate="True" perm_permissions="True">
27.            <div class="sfContentBlock">
28.               <p style="display: inline;>  
29.               </p>
30.            </div>
31.         </div>
32.      </td>
33.      <td class="rdRight"> </td>
34.   </tr>
35.   <tr class="rdBottom">
36.      <td class="rdLeft"> </td>
37.      <td class="rdCenter"> </td>
38.      <td class="rdRight"> </td>
39.   </tr>
40.</table>

<p style="width:12px>
a breaks </
p>
<p style="width:12px> breaks </p>
<p style="width:12px> breaks </p>
<p style="width:12px> breaks </p>

Posted by Community Admin on 20-Jan-2011 00:00

Hello Lasse,

I managed to reproduce the issue you are reporting. The problem has been logged at our bug tracking system (ID 105361).

When you use ConentBlock and switch from "Html" to "Design", before you clock Save the  markup is completed as a  valid.

Thanks for your finding!


All the best,
Milena
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

This thread is closed