Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[SOLVED] How2 show \r\n in code
#1
When I put a code listing in CKEDIT, it removes all backslashes such a c language return & newline.
How can I force CKEDIT not to modify text?

i.e
Code:
printf("some text\r\n");
becomes
printf("some textrn");
Thanks,
jwzumwalt
(\__/)
(='.'=)
(")_(")
Reply
#2
Use entities or put it in code or pre tags?
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#3
(2016-01-15, 23:09:04)shawn_a Wrote: Use entities or put it in code or pre tags?

Neither <pre>, <code>, or <xmp> (or both, or all) solve the problem.

I don't know what you mean by entities?
Thanks,
jwzumwalt
(\__/)
(='.'=)
(")_(")
Reply
#4
Does it happen also with ckeditor disabled?
Reply
#5
I do not see this behavior.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#6
I don't either. Tested again with magic quotes enabled too.
Perhaps some plugin...
Reply
#7
(2016-01-16, 03:29:36)Carlos Wrote: I don't either. Tested again with magic quotes enabled too.
Perhaps some plugin...

Thanks for the replies.

This has been a constant issue since I first started using GS a month ago. CKEDIT keeps screwing with code format. If I want a <br>, it usually replaces with <p>&nbsp;</p>. If I want a line indented for clarity, it re-indents the way it thinks it should be. The list goes on....

Is there other options for text editors?
I am using the default ckedit 3.xxx that came with GS, how can I upgrade to 4.x?

Other than this problem, I now have GS working pretty much how I want and really like it.
Thanks,
jwzumwalt
(\__/)
(='.'=)
(")_(")
Reply
#8
That is entermode_br settable.

Install the cke_patch plugin for 4.x

There are alot of options for ckeditor to change its behavior, and the docs are not that user friendly.

is it possible you have a plugin or a gsconfig setting messing your settings up ?
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#9
(2016-01-16, 07:29:58)shawn_a Wrote: That is entermode_br settable.

Install the cke_patch plugin for 4.x

There are alot of options for ckeditor to change its behavior, and the docs are not that user friendly.

is it possible you have a plugin or a gsconfig setting messing your settings up ?

Well, none of the above fixed the problem.

UPDATE:
After considerable switching back and forth between a fresh GS install, I found it was the "Custom Title" plugin that was causing the trouble Sad

Thanks for all the help
Thanks,
jwzumwalt
(\__/)
(='.'=)
(")_(")
Reply




Users browsing this thread: 1 Guest(s)