Announcement

Collapse
No announcement yet.

Chrome leading space characters not properly escaped

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • talos2
    replied
    Update: I screwed up. I thought I had eliminated the possibility that my running an html+css+js minifier caused this problem - it turned out that that was the issue. Still tracking down exactly what caused it, but the upshot is that some file's character encoding was not preserved and that led to this issue.

    Sorry for the false alarm - hopefully this post proves helpful to someone down the line...

    Leave a comment:


  • talos2
    replied
    Ok, well, two things:

    1. My use of CKEditor is not in a vacuum or somehow separate from VB. It is used as embedded in VB and installed/upgraded per your instructions. There are no template or code modifications.

    2. Even assuming this is a CKEditor-specific problem - which could very well be the case - given that this is the editor you chose to use and that you eliminated any ability to remove rich text editing (I would actually really have preferred the option to simply turn CKEditor off) - then I'm not left with many options here - except to possibly fix the bug myself.

    I'm going to do my best here to figure this out - hopefully someone has experienced this and can help along the way or make use of my findings. So - couple of further findings: If I manually switch the encoding on the page to either "Auto-Detect" or "UTF-8" then the problem goes away. But, in both my configuration and on vbulletin.com the page is served with Content-Type:text/html; charset=ISO-8859-1. Oddly this still results in a working setup on vbulletin.com, but not in my case.

    I've verified also that my copy of ckeditor-rollup-519.js is identical to what is served by vbulletin.com - as copy/pasted from what the browser actually received. And running 'file' on this file reports that it is UTF-8 encoded. So I didn't somehow mess up the file encoding of the CKEditor source while copying it over to the server.

    I'll update as I have further info. Side question: is there a way to run VB in UTF-8 mode? I actually would sort of expect that to be an option somewhere just because I expect there are boards out there running in other languages and UTF-8 is pretty much an agreed upon standard for such things yes?

    Leave a comment:


  • Wayne Luke
    replied
    This would be an error in CKEditor. You would have to bring it up with them. We don't do anything special for leading spaces in vBulletin itself.

    Leave a comment:


  • talos2
    started a topic Chrome leading space characters not properly escaped

    Chrome leading space characters not properly escaped

    I'm experiencing an odd problem on my board: leading space characters are being improperly escaped. The CKEditor attempts (correctly) to preserve leading space characters on a given line to   but on Chrome only it's instead converting these to this sequence of chars:

    Code:
     
    That string, verbatim, is what I see posted on the forum instead of a leading space. This happens on its own and also inside [code] blocks.

    This affects only leading spaces, not spaces between words or trailing space. I wasn't able to replicate this on this board (in the test forum). The problem is not storage related - the browser is actually submitting the improper character sequence to the server. This is a snippet of what I see being POSTed to the server in the network tab of the Chrome developer console:

    Code:
    Content-Disposition: form-data; name="text" 
    
    &#194;&#160;<-- this should be a space
    And this is what I see when I perform the same test on this (vbulletin.com) board:

    Code:
    Content-Disposition: form-data; name="text" 
    
    &nbsp;<-- this should be a space
    I'm running 5.1.19 as an upgrade all the way from the 3.x series (which did not have this issue). I've looked here, on JIRA and elsewhere on the web and I've seen other Chrome-related issues that seem similar, but are not this specific problem. This stackexchange article may be relevant:

    http://stackoverflow.com/questions/1...nstead-of-nbsp

    Any help would be appreciated. Thanks guys.

Related Topics

Collapse

Working...
X