AndyPSV Posted April 21, 2014 Share Posted April 21, 2014 eregi_replace('[0-9]+\.+[0-9]','',$cart['unit']); How to change it to preg_replace? I get an error: Warning: preg_replace() [function.preg-replace]: Unknown modifier '+' in --- Link to comment https://forums.phpfreaks.com/topic/287911-how-to-eregi_replace-to-preg_replace/ Share on other sites More sharing options...
AndyPSV Posted April 21, 2014 Author Share Posted April 21, 2014 preg_replace('#[0-9]+\.+[0-9]#i','',$cart['unit']); solved Link to comment https://forums.phpfreaks.com/topic/287911-how-to-eregi_replace-to-preg_replace/#findComment-1476837 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.