Code: Select all
$plain = "INSERT INTO storyentries (p_id, e_id, c_id, e_imp, e_email, e_title, e_text, e_url, e_create, IP ) VALUES ('2', '420', '11977','1','test@test.com','Test Title','Normal text with CR and extra chars','http://www.test.com',NOW(),'127.0.0.0' )";
Code: Select all
preg_match("/^INSERT INTO entries \(p_id, e_id, c_id, e_imp, e_email, e_title, e_text, e_url, e_create, IP \) VALUES \('(?P<page_id>\d+)', '(?P<entry_id>\d+)', '(?P<ortid>\d+)','(?P<entry_importance>\d+)'/", $plain, $treffer);
I am not able to get the text stuff working at all.
Any help would be appreaciated.