<input type="text" name="name" value="">
I am trying to remove the value="" from the string using preg_replace can anyone help I am not clued up with regex at all
<input type="text" name="name" value="">
I am trying to remove the value="" from the string using preg_replace can anyone help I am not clued up with regex at all
 
    
     
    
    You don't need preg_replace if it's only value="". Use str_replace which is faster than using regex.
$string = '<input type="text" name="name" value="">';
print(str_replace('value=""','',$string)); //<input type="text" name="name" >
