Adding <pre> tags and escaping special characters