JQuery Adding multiple classes to a div tag

javascript, jquery

Solution

Try this:

$('<div/>', {"class": "something something_else" })

Problem

I would like to obtain the next line of code using JQuery: ``` <div class="something something_else"> </div> ``` I use `$(document.createElement('div'));` to create the div, but then how do I add `something` and `something_else` to the div? I'm sure it's something basic, but I can't seem to figure it out.

Original source