<?php
$subject = "You have been assigned to the job #3 Megastar 4(01923033)
OSD jackpot needs adjusting.
The job is for Icon's Stadium Bar - GMV1028.
The job machines are - 01980414 , - 01923033 , - 07993682
This job has a priority of Non-Critical Fault / Medium.
The job is scheduled for Monday, 14 July, 2014 at 02:29 PM.";
//$subject = str_replace( '#', '', $subject );
mysql_real_escape_string($subject);
function safe($value){
return mysql_real_escape_string($value);
}
$subject = safe($subject);
print_r($subject);
$var['machine']="1Action == machine";
preg_match("/(?<!\d)\d{8}(?!\d)/", strip_tags($subject), $matches);
$var['serial']=$matches[0];
print_r($var['machine']);
print_r($var['serial']);
Fatal error: Uncaught Error: Call to undefined function mysql_real_escape_string() in /in/7kEoN:10
Stack trace:
#0 {main}
thrown in /in/7kEoN on line 10
Process exited with code 255.
Fatal error: Call to undefined function mysql_real_escape_string() in /in/7kEoN on line 10
Process exited with code 255.
Output for 4.3.2 - 4.3.11, 4.4.0 - 4.4.9
Warning: mysql_real_escape_string(): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) in /in/7kEoN on line 10
Warning: mysql_real_escape_string(): A link to the server could not be established in /in/7kEoN on line 10
Warning: mysql_real_escape_string(): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) in /in/7kEoN on line 15
Warning: mysql_real_escape_string(): A link to the server could not be established in /in/7kEoN on line 15
Notice: Undefined offset: 0 in /in/7kEoN on line 33
1Action == machine
Output for 4.3.0 - 4.3.1
Warning: mysql_real_escape_string() [http://www.php.net/function.mysql-real-escape-string]: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) in /in/7kEoN on line 10
Warning: mysql_real_escape_string() [http://www.php.net/function.mysql-real-escape-string]: A link to the server could not be established in /in/7kEoN on line 10
Warning: mysql_real_escape_string() [http://www.php.net/function.mysql-real-escape-string]: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) in /in/7kEoN on line 15
Warning: mysql_real_escape_string() [http://www.php.net/function.mysql-real-escape-string]: A link to the server could not be established in /in/7kEoN on line 15
Notice: Undefined offset: 0 in /in/7kEoN on line 33
1Action == machine