WordPress.org

Make WordPress Core

Ticket #11690: 11690.diff

File 11690.diff, 778 bytes (added by nacin, 4 years ago)
  • wp-includes/formatting.php

     
    22992299/** 
    23002300 * Escape single quotes, htmlspecialchar " < > &, and fix line endings. 
    23012301 * 
    2302  * Escapes text strings for echoing in JS, both inline (for example in onclick="...") 
    2303  * and inside <script> tag. Note that the strings have to be in single quotes. 
    2304  * The filter 'js_escape' is also applied here. 
     2302 * Escapes text strings for echoing in JS. It is intended to be used for inline JS 
     2303 * (in a tag attribute, for example onclick="..."). Note that the strings have to 
     2304 * be in single quotes. The filter 'js_escape' is also applied here. 
    23052305 * 
    23062306 * @since 2.8.0 
    23072307 *