Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sanitize column headers #13

Open
kelle opened this issue Oct 2, 2015 · 3 comments
Open

sanitize column headers #13

kelle opened this issue Oct 2, 2015 · 3 comments
Assignees
Labels

Comments

@kelle
Copy link
Contributor

kelle commented Oct 2, 2015

Error: Syntax error, unrecognized expression: .target#yrs since phd_(-3.037, 4.4]

@bmcfee bmcfee self-assigned this Oct 5, 2015
@bmcfee bmcfee added the bug label Oct 5, 2015
@bmcfee
Copy link
Collaborator

bmcfee commented Oct 5, 2015

This is because we use raw column headers from the csv input as dom element ids and css classes.

It of course isn't helped by our conversion of numerical values to interval memberships with headers like age_[23.45552, 32.948889) which break CSS pretty hard. Spaces are also problematic for similar reasons

We'll need to find a way to sanitize strings to be safe for use as CSS classes and dom ids. UrlEncode would probably work, but feels a little too clumsy. Maybe someone out there has already solved this problem? I'll do some digging.

@kelle
Copy link
Contributor Author

kelle commented Oct 5, 2015

I don't completely understand but for the short term, please just be
specific about what's allowed and not allowed in csv file. If you state it
here, I can update the docs.

On Monday, October 5, 2015, Brian McFee [email protected] wrote:

This is because we use raw column headers from the csv input as dom
element ids and css classes.

It of course isn't helped by our conversion of numerical values to
interval memberships with headers like age_[23.45552, 32.948889) which
break CSS pretty hard. Spaces are also problematic for similar reasons

We'll need to find a way to sanitize strings to be safe for use as CSS
classes and dom ids. UrlEncode would probably work, but feels a little too
clumsy. Maybe someone out there has already solved this problem? I'll do
some digging.


Reply to this email directly or view it on GitHub
#13 (comment)
.

kelle
(via iOS)

@bmcfee
Copy link
Collaborator

bmcfee commented Jan 14, 2016

This issue may be obviated by the discussion in #12. If we rewrite the interface to avoid exposing/requiring binarized columns, much of this will become simpler.

The real resolution of this will require discussion with a js developer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants