| 1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> |
|---|
| 2 | <html> |
|---|
| 3 | <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> |
|---|
| 4 | |
|---|
| 5 | <head> |
|---|
| 6 | <title>Ticket #1605</title> |
|---|
| 7 | <script type="text/javascript" src="fckeditor/fckeditor.js"></script> |
|---|
| 8 | <script type="text/javascript"> |
|---|
| 9 | <!-- |
|---|
| 10 | function InsertText() |
|---|
| 11 | { |
|---|
| 12 | var htmltext = "This is <b>some <span style=\" color: maroon; \" >HTML</span></b> text with colors formatted." ; |
|---|
| 13 | var obFCK = FCKeditorAPI.GetInstance('TXT'); |
|---|
| 14 | obFCK.InsertHtml(htmltext); |
|---|
| 15 | } |
|---|
| 16 | |
|---|
| 17 | function InitPage() |
|---|
| 18 | { |
|---|
| 19 | |
|---|
| 20 | |
|---|
| 21 | var oFCKeditor = new FCKeditor( 'TXT' ) ; |
|---|
| 22 | oFCKeditor.BasePath = "fckeditor/" ; |
|---|
| 23 | oFCKeditor.Height = 340 ; |
|---|
| 24 | oFCKeditor.Width = 600 ; |
|---|
| 25 | oFCKeditor.ReplaceTextarea(); |
|---|
| 26 | |
|---|
| 27 | } |
|---|
| 28 | |
|---|
| 29 | // --> |
|---|
| 30 | </script> |
|---|
| 31 | </head> |
|---|
| 32 | <body onload="InitPage()"> |
|---|
| 33 | <form> |
|---|
| 34 | <textarea name="TXT" id="TXT">Hello, I am Mister X ... </textarea><br> |
|---|
| 35 | <button type="button" name="InserHTML" onclick="InsertText()" >Insert HTML</button><br> |
|---|
| 36 | Steps to reproduce:<br> |
|---|
| 37 | 1. Press InsertHTML<br> |
|---|
| 38 | 2. Switch to Source View<br> |
|---|
| 39 | 3. Switch to WYSIWYG view again |
|---|
| 40 | </form> |
|---|
| 41 | </body> |
|---|
| 42 | </html> |
|---|