I'm having some problem with regex and replacing certain content. All my forms are stored in a field of a table and so when they are queried they all have a checkbox next to a field if it is required. I want to find all checkboxes and replace them with either <em>*</em> or '' (blank space).
Here is what I'm trying to make work.
Code: Select all
preg_replace('/<input(.*?)id="(.*?)-required" type="checkbox"(.*?)>/','',$Content);