No matter what i'm trying to do I get the following error:
Notice: Undefined offset: 0 in /var/www/html/new.php on line 54
Notice: Undefined offset: 0 in /var/www/html/new.php on line 54
Notice: Undefined offset: 0 in /var/www/html/new.php on line 54
Notice: Undefined offset: 0 in /var/www/html/new.php on line 54
Here is the raw code:
Code: Select all
if (preg_match ( '/(?<=">).*(?=<\/revision>)/', $xml, $revision ) == 0) {
$revision = array(0 => "--");
}
preg_match ( '/(?<=parent=").*(?=" uid="\d+")/', $xml, $machineID );
preg_match("/\d+/", $machineID[0], $ip);
So when the loop "runs" on the array it should print out only 02 03 04 05 and I won't get this stup** error everytime...
Please Advise,
Roy.