Fix bug: can't show image
Fix bug: getAttribute is undefined