I have a variable var 'html', it contains some html codes .in it there is a div with id messages. I want to get only that div contents from the ‘html’ variable into another variable using javascript.
Please help . .
I have a variable var ‘html’ , it contains some html codes .in it
Share
The easiest way with jQuery in my opinion: