Resolved! Marg found the problem...an apostrophe was the culprit! Replaced with \' and it works fine!

What can I say...I'm new to php!