>
> This is a PHP function that escapes strings so you can output them as a
> JS string. IIRC it assumes you're using single quotes to enclose your
> strings.
>
> /**
> * Function to appropriately escape a string so it can be output
> * into javascript code.
> *
> * @p
> ...
This is a PHP function that escapes strings so you can output them as a
JS string. IIRC it assumes you're using single quotes to enclose your
strings.
/**
* Function to appropriately escape a string so it can be output
* into javascript code.
*
* @param string $stri
Hello,
I'm adding functionality to allow a user to copy data on a page to the
clipboard using JS. This can be done simply with:
window.clipboardData.setData('Text','String to copy to clipboard');
The string from PHP needs to contain line breaks when copied into the
clipboard. This works when I
3 matches
Mail list logo