Made html title grabbing more stable