modify method of html and append