i need to replace combobox like this. eg:-
<select sistem="" name="answer5" >
<option>math</option>
<option>science</option>
<option selected="selected">engineering</option>
<option>English</option></select>
result shuld be(AFTER REPLACED) :- {answer5}
i have tried this but failed:
preg_replace('|<SELECT(.*)name="'.$name.'"(.*)>(.*)</SELECT>|U', '{'.$name.'}',$string);