update method to change p tag