Problems, need help? Have a tip or advice? Post it here.
11 posts Page 1 of 2
Hi,

I'm working on a new site again with couchcms and so far still very good. I've downloaded 1.3, because I wanted to use repeatable regions. This works fine, but when pasting from Word into nicedit I get the following error:

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator to inform of the time the error occurred and of anything you might have done that may have caused the error.

More information about this error may be available in the server error log.



When pasting without formatting (through notepad for instance) no problem. So I think nicedit (I haven't tested it outside a repeatable region) can't handle the formatting code from word.

Anything I can do about it?
Hi,

Pasting text copied right out of a Word document is not a recommended practice for any richtext editor.

Let alone Nicedit, even heavy-weights the like of CKEditor are known to flounder handling all the proprietary markup cruft contained in MS Word formatted text.
In all fairness, CKEditor has a configuration option that can be enabled in includes/ckeditor/config.js (config.forcePasteAsPlainText), but the results are not always clean.

I can only say that first pasting Word contents into a plain-text editor and then transferring it to the richtext editor is our only recourse.
Hi,

I'm aware of the garbage that Word produces. But I'm also aware that 90% of people copy their text from Word even if I warn them strictly not to. In CK editor this results in unwanted results, and while that's not ideal, it is acceptable.

A server error is something that will be perceived as a bug and will be very hard to sell to users.
Yes, you are right.

Could you please send me the exact Word text that is causing this behaviour? (attaching the original Word file would be fine).
I'll try and recreate the issue on my test machine. Maybe something can be done to rectify it.

Thanks
Thank you for sending me the Word file (and the editable region's definition).

I used them to recreate the issue on my test machines but everything works just fine (except that a lot many <o :p></o> tags show up, which was expected).

So maybe the issue is not with nicedit per se but has to do something with your system's configuration.
I say this because I've seen similar error being reported on servers that had Suhosin type PHP hardening security in place.
In those cases some particular words in the text being inputted were causing the security system to balk (e.g. 'system').

Could you please take a look at your web server's error log? This could give us further clue into the matter.
If possible, grant me access to your site and I'd happy to look into the matter in more depth.

Thanks.
Hi Kamran,

I've been able to nail it down more specifically.

This is the error:
Premature end of script headers: php5.fcgi, referer: http://(-removed-)/?act=edit&tpl=6&nonce=bd9e409fcdaca0bfbb989874212a4e0c


But I've also found out that it is a very specific scenario. This only happens when pasting from Word on a MAC. It doesn't happen on a PC and it doesn't happen when I open the file with another editor on the MAC. The cause is probably the hundreds lines of xml code that it drops in the field with the text, like:

Code: Select all
<!--[if gte mso 9]><xml>
<o:DocumentProperties>
  <o:Revision>0</o:Revision>
  <o:TotalTime>0</o:TotalTime>
  <o:Pages>1</o:Pages>
  <o:Words>39</o:Words>
  <o:Characters>218</o:Characters>
  <o:Company></o:Company>
  <o:Lines>1</o:Lines>
  <o:Paragraphs>1</o:Paragraphs>
  <o:CharactersWithSpaces>256</o:CharactersWithSpaces>
  <o:Version>14.0</o:Version>
</o:DocumentProperties>
<o:OfficeDocumentSettings>
  <o:AllowPNG/>
</o:OfficeDocumentSettings>
</xml><![endif]-->
etc..


Not sure if this would happen on another server, but this is so very specific that it's not worth the trouble. I'll give it a test on another server when I upgrade another site to see if this is expected behaviour (might take a few weeks).
Please do keep us posted.
Thanks.
Hello KK,

I get the below same error while uploading images. a little help?

Internal Server Error

The server encountered an internal error or
misconfiguration and was unable to complete
your request.

Please contact the server administrator at
webmaster@domain.co.ke to inform them of the time this error occurred,
and the actions you performed just before this error.

More information about this error may be available
in the server error log.

Additionally, a 500 Internal Server Error
error was encountered while trying to use an ErrorDocument to handle the request.
Hello Harry,

I'd suggest you please take a look at the server's error log. It should have something to give us a clue about the cause.
Hello KK,

Looked into my server error log and there are none.
11 posts Page 1 of 2
cron