Fix for commas in attribute values

Escape commas in attribute values to avoid them being thrown as separate attributes