updated to support external html