Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

text box leaks garbage out

#43

if i load up a text box with text "hello world" and then pull it back out with wf:q I get "hello world" out where the space is a 160 space rather than a normal one. any idea whats going on here?

Reported by Matt O'Gorman · April 8th, 2010 @ 05:55 AM

State: new
Milestone: none
Assigned to: Rusty Klophaus Rusty Klophaus

Activity

  1. Brian O
    Brian O

    Yes. wf:html_encode() converts spaces to non breaking spaces (among a few other things). This is sometimes an OK feature for display purposes (if that's what you want), but is disastrous in a case like this.

    I would submit that html_encode() should not encode spaces and tabs, but should concern itself with only encoding quotes ('"), angle brackets (<>), and ampersands (&). It's an easy fix. Just remove those other cases from wf_convert:html_encode().

    As a workaround, you can do:

    #textbox{html_encode=false, my_own_html_encode_that_does_not_encode_spaces(Value)}
    

    I believe this should be fixed at the framework level. Nitrogen has this great automatic HTML encoding, but we can't use it because of this.

    April 22nd, 2010 @ 01:33 PM

  2. Rusty Klophaus
  3. Rusty Klophaus
    Rusty Klophaus
    • Milestone cleared.
    • Milestone order changed from 0 to 0

    June 29th, 2010 @ 08:00 PM

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.