Make ParseHTML more general