Updated internal handling of HTML attributes