Opened 6 years ago

Closed 6 years ago

#7996 closed Bug (fixed)

Invalid table code creates error

Reported by: vosmanz Owned by:
Priority: Normal Milestone:
Component: Core : Tables Version: 3.5.1
Keywords: Cc:

Description

When I insert a table with an incorrect colspan in the first row, and then try to 'insert row before' in the second row, I get a javascript error:

'rowSpan is empty or not an object' in plugins/tabletools/plugin.js on line 142.

Used code:

<table border="1" cellpadding="1" cellspacing="1" style="width: 500px" summary="">
	<tbody>
		<tr>
			<td colspan="3">
				&nbsp;</td>
		</tr>
		<tr>
			<td>
				&nbsp;</td>
			<td>
				&nbsp;</td>
		</tr>
	</tbody>
</table>

Steps:
1 - Paste the code in the editor.
2 - Right-click in the second row.
3 - Choose 'Row' -> 'Insert row before' (I use dutch language, so translation might be different)
4 - Get a javascript error

I know the code is 'wrong' (colspan="3" should be colspan="2"). However, it should be great if this could be fixed by CKeditor because now you can't edit the table when, for example, you copy bad code from another website.

Because of bug #7896, this now can only be fixed when the user has source-mode available.

Only tested in IE8 (win7), using CKEditor 3.6.
Also tested in nightly build.

Change History (4)

comment:1 Changed 6 years ago by Jakub Ś

Status: newconfirmed
Version: 3.63.5.1

Applicable for all browsers (except Opera) from CKEditor 3.5.1.

comment:2 Changed 6 years ago by Jakub Ś

Forgot to paste the error. Sorry.

Message: cloneRow[i] is undefined
URI: /ckeditor/_source/plugins/tabletools/plugin.js
Line: 142

comment:3 Changed 6 years ago by Jakub Ś

Summary: IE8: Invalid table code creates errorInvalid table code creates error

This issue was duplicated in #8214

comment:4 Changed 6 years ago by Jakub Ś

Resolution: fixed
Status: confirmedclosed

This issue no longer occurs in latest CKEditor 3.6.2

Note: See TracTickets for help on using tickets.
© 2003 – 2017 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy