Ticket #8335 (confirmed Bug)

Opened 3 years ago

Last modified 3 years ago

javascript error regularly in this situation

Reported by: pgteam Owned by:
Priority: Normal Milestone:
Component: General Version: 3.0
Keywords: IE Cc:

Description

reproduce as below:

  1. type three lines
  2. first line bold,
  3. second line italic,
  4. third line underline,
  5. copy all of them, paste at the end of third line,
  6. after several pasted, unexpected empty paragraph appeared.
  7. type something in this empty paragraph,
  8. after typed, try to bold, italic or underline,
  9. it doesn't work and after several pressing or hotkey about bold, italic and underline.
  10. javascript error shows "null" is null or not an object, line 116, char: 2337.

IE8, Windows XP sp3 Ckeditor3.6.1, javascript

Attachments

ie8_selection.png (10.4 KB) - added by j.swiderski 3 years ago.

Change History

comment:1 Changed 3 years ago by j.swiderski

  • Status changed from new to pending
  • Keywords null is null or not an object removed
  • Version 3.6.1 deleted

Your description of a problem is very unclear. Could I ask you to simplify your description as much as possible so that we could easily sit down and look at steps you have provided and reproduce it.

Things that are unclear:

type three lines

How those lines should be typed? Do you turn on formatting (bold), type, turn off formatting, press enter (maybe SHIFT+ENTER) and turn on another formatting (italic)? If not please describe it more clearly.
Also happens before copying text? Do you turn of underline or leave it?

copy all of them, paste at the end of third line,

What enter mode is used here? If default ENTER_P than it is not possible to paste copied contents at the end of third line.

after several pasted, unexpected empty paragraph appeared.

how many is several?

after typed, try to bold, italic or underline,

Do you select the text or keep the cursor at the end of line and just press bold?

I really would like to reproduce this bug but I need clear description of the problem and clear scenario allowing me to reproduce it.

comment:2 Changed 3 years ago by j.swiderski

Comment made by @pgteam in #8302 and should have been made here.

Thanks for your comment, here we go ! To reproduce:

  1. by using the ckeditor/demo
  2. clear all content 1st.
  3. enter several lines e.g. line number 1 line number 2 line number 3

ps: for code view , it should be : <p>

line number 1</p>

<p>

line number 2</p>

<p>

line number 3</p>

  1. select and style these line by bold, italic and underline (hot key) separately.

ps: for code view, it should be like this: <p>

<strong>line number 1</strong></p>

<p>

<u>line number 2</u></p>

<p>

<em>line number 3</em></p>

  1. Ctrl+A to select all and copy
  2. Paste the copied content in the second line where cursor position at "line number 2",

( that's mean paste after "line nu" and before "mber 2" )

  1. after pasted, DONT switch to view source mode, you will see there are some line break between last few lines.
  1. select across "line number 3" + some line break + "mber 2" ( "line number 3" should be italiced and underlined , "mber 2" should be underlined )
  1. after this selection, press the underline icon by using left click.
  1. javascript error alerted. ('type' is null of not an object )

ps: screen shot attached to here http://cksource.com/forums/viewtopic.php?f=11&t=23373&p=59617#p59617

comment:3 Changed 3 years ago by j.swiderski

  • Status changed from pending to confirmed
  • Keywords IE added
  • Version set to 3.0

Comment made by me in #8302 and should have been made here.

@pgteam thank you for your description.

Simplified test case:

  1. Open replacebycode sample, switch to source and paste the below code:
    <p>
    	<strong>line number 1</strong></p>
    <p>
    	<u>line number 2</u></p>
    <p>
    	<em>line number 3</em></p>
    
  2. Switch to WYSIWYG,
  3. Click inside editor, press CRTL+A, CRTL+C
  4. Place the cursor in “line number 2”
  5. Press CRTL+V
  6. As show on ie_selection.png, select line number 3 + mber 2 and empty space
  7. Press bold, italic or underline

Result: JS terror is thrown:

Message: 'type' is nul lor not an object
Line: 63
URI: /3.6.1/ckeditor/_source/core/dom/walker.js

Issue is reproducible in IE8 and IE9 from CKE 3.0

Additionally in IE9 when pasting copied contents different JS error is thrown:
Message: Can’t get “nodeValue” object is either null or undefined
Line: 802
URI: _source/plugins/selection/plugin.js


In IE7 and IE6 there is no JS error but the behavior is also invalid. The behavior is different depending on a CKE version so I’m presenting the results for latest stable CKE 3.6.1

The scenario is the same as above:

Step 5 doesn’t produce empty line when pasting
Result: After selecting line “number 3 + mber 2” and pressing bold, only “mber 2” gets bolded.

Changed 3 years ago by j.swiderski

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