I'm looking for a preg_replace that can replace " with ' when between font-family: and ;
I'm having an issue with my some dynamic html I'm using which requires me to replace the quotes with single quotes in my style attribute. Font and Font-family attributes can sometimes have quotes when they have spaces in the names but that is causing issues rendering the html. I haven't fully got a handle on how to use preg_replace so I'm hoping somebody can lend me a hand.
This is an example of the string: <span style="font-weight:bold;font-family:"franklin gothic medium",arial,helvetica,sans-serif;font-size:29px"="">Made in the USA!</span>
From how I though preg_replace worked I tried the following but it didn't work: preg_replace("/font\-family\:[\"]+?\;/", "'", $string);