This is a migrated thread and some comments may be shown as answers.

Mossimagemanager & table problems

4 Answers 93 Views
WebParts for SharePoint
This is a migrated thread and some comments may be shown as answers.
Nil
Top achievements
Rank 1
Nil asked on 18 Mar 2008, 04:24 PM
Hi.
We are using the latest full version (4.5.1.0) of the radeditor for Moss2007.
For inserting images, we want to user the Mossimagemanager instead of the Radeditor one.(For the browsing capabilities)
This works mostly fine, except when you try to insert an image into a table cell.
I'm adding a table with "Insert table" and the following html is generated:(kept it simple here, just one cell)

<table cellspacing="0" cellpadding="0">
    <tbody>
        <tr>
            <td> </td>
        </tr>
    </tbody>
</table>


Everything fine so far. but when I want to insert an image to the cell something goes wrong:(I'm placing the cursor inside the cell then click add image)

<table cellspacing="0" cellpadding="0">
    <tbody>
        <tr>
            <img alt="" style="border-right: 0px solid; border-top: 0px solid; border-left: 0px solid; border-bottom: 0px solid" src="http://moss2007/PublishingImages/pic.jpg" border="0" />
        </tr>
    </tbody>
</table>

Seems that "something" is removing my <td> and </td> tags.

Any idea why? Can it be easily fixed? I've been poking around MOSSEditorTools.js but I'm not so familiar with javascripts...

Regards
Thomas






4 Answers, 1 is accepted

Sort by
0
George
Telerik team
answered on 20 Mar 2008, 01:48 PM
Hi Nil,

Thank you for the bug report - I logged it in out ToDo list for fixing in one of the future updates. 

Your points were updated.


Best regards, George
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Nil
Top achievements
Rank 1
answered on 20 Mar 2008, 03:35 PM

Hi.
We might have solved it already, maybe you can benefit:

In MOSSEditorTools.js there is a "function":
RadEditorCommandList["MOSSImageManager"] = function(commandName, editor, oTool)

Here is how we did it: (We used appendChild instead of replaceChild)

   if (elemToReplace !=null)
   {
    var parentEl = elemToReplace.parentNode;
    elemToReplace.appendChild(elemImage); // BUGFIX
    //parentEl.replaceChild(elemImage, elemToReplace); // BUGFIX
    return; 
   }

Don't know(yet) if it affects something else.
But this works for us now.

Happy easter
Thomas

0
MrMatt
Top achievements
Rank 1
answered on 16 Jan 2009, 10:09 PM
Hi,

We are experiencing the same behavior with images in tables with 4.5.1.  Was this bug ever fixed, if so what version was it fixed in?

Thanks!
0
Lini
Telerik team
answered on 19 Jan 2009, 10:58 AM
Hi,

This bug was fixed in version 4.53. If you upgrade to the latest available 4.x build (4.54), you should have no problems. If you cannot find the 4.x build in your account (it should be in the RadControls for ASP.NET downloads section), please open a formal support ticket.

Sincerely yours,
Lini
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
WebParts for SharePoint
Asked by
Nil
Top achievements
Rank 1
Answers by
George
Telerik team
Nil
Top achievements
Rank 1
MrMatt
Top achievements
Rank 1
Lini
Telerik team
Share this question
or