Simple parsing of tag type and attributes