Translations:DOM-based XSS/40/en

For the most simple case (inserting user-controlled data into the text of an element), you can use jQuery's $1 method or $2.