Questions tagged [html-escape]

50 questions
0
votes
1 answer

angular: create formating filter without html-escaping

I want to do automatic html formatting for some strings. For example, I want to do automatic subscripts for a char that is prefixed with an underline. So a string like "U_1 + U_2 = U_3" should be formatted to U1 + U2 = U3 This looks like a perfect…
Meier
  • 3,858
  • 1
  • 17
  • 46
0
votes
2 answers

How can I unescape HTML escape character from JSP to Java

I am applying fn:escapeXml to a input value (say >) in JSP to do html escape. When I submit the form, I do need to send the parameter to the controller. In my controller, the request parameter comes as > and not >. Because of this, I could not…
sridhar
  • 1,117
  • 5
  • 31
  • 59
-1
votes
2 answers

What are the benefits of using <%- tag v/s <%= tag in ejs?

When should one use the <%- tag? Since the <%- is unescaped, wouldnt it just leave the application vulnerable to attacks?
lightbringer
  • 399
  • 4
  • 19
-1
votes
1 answer

Adding "" to a certain word using handlebars.js

I am using handlebars for JavaScript templating. I want to add around the word "success". I would hopefully want to escape any other html or scripts in the text.
Joe
  • 7,922
  • 18
  • 54
  • 83
-2
votes
1 answer

How to convert html attribute code to string

I have this js code: var my_elem = document.querySelector("[action='/cart/add']"); but I need to make it a string, so I can use it as a string variable. How I can do that? I already tried: 'var my_elem =…
Aleks Per
  • 1,549
  • 7
  • 33
  • 68
1 2 3
4