You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What operating system and processor architecture are you using?
linux/amd64
What did you do?
I'm working on an HTML sanitizer, where I want to access the original escaped HTML attribute values during the parse.
What did you expect to see?
An ideal solution to me would be a flag in the Tokenizer which could indicate if unescaping is required or not when calling TagAttr().
If you find this useful, i can implement it, or if you have any better idea, please reply.
What did you see instead?
As I see, currently the only option is Tokenizer.TagAttr() which automatically unescapes attribute values: https://github.com/golang/net/blob/master/html/token.go#L1158 .
Escaping again the unescaped attribute values can be a solution, but that re-escaping adds computational and structural complexity to the program what I want to avoid if possible.
thanks,
a
The text was updated successfully, but these errors were encountered:
What version of Go are you using?
go1.7.3
What operating system and processor architecture are you using?
linux/amd64
What did you do?
I'm working on an HTML sanitizer, where I want to access the original escaped HTML attribute values during the parse.
What did you expect to see?
An ideal solution to me would be a flag in the
Tokenizer
which could indicate if unescaping is required or not when callingTagAttr()
.If you find this useful, i can implement it, or if you have any better idea, please reply.
What did you see instead?
As I see, currently the only option is
Tokenizer.TagAttr()
which automatically unescapes attribute values: https://github.com/golang/net/blob/master/html/token.go#L1158 .Escaping again the unescaped attribute values can be a solution, but that re-escaping adds computational and structural complexity to the program what I want to avoid if possible.
thanks,
a
The text was updated successfully, but these errors were encountered: