Skip to main content
Inspiring
March 3, 2010
Question

Escaping html for dynamic javascript

  • March 3, 2010
  • 1 reply
  • 395 views

Hi Folks,

Can anyone please tell me how I escape html for use in a  function?

Here is my code:

onMouseover="ddrivetip('#jobdescription#','white', 300)";

Thanks in advance

    This topic has been closed for replies.

    1 reply

    Owainnorth
    Inspiring
    March 3, 2010

    Hi there

    What is it you're trying to escape exactly? Do you mean you want the literal # signs to go in? If that's the case then use a double hash ## - Coldfusion will render a single one to the browser.

    If that's not what you mean then some more info may be required

    O.