fix the encode issue  of  attribute's value

when the value of attribute has chinese character or 'ä' and so on，the
output of $.html() or $.xml() is not correct, the character of output is
convert just like  htmlentities.