@ 2014-10-10T08:59:22Z <?php
$whitespace = array(
"\u0009" => 'character tab',
"\u000a" => 'line feed',
"\u000b" => 'line tab',
"\u000c" => 'form feed',
"\u000d" => 'carriage return',
"\u0020" => 'space',
"\u0085" => 'next line',
"\u00A0" => 'non-breaking space',
"\u1680" => 'ogham space',
"\u2000" => 'en quad',
"\u2001" => 'em quad',
"\u2002" => 'en space',
"\u2003" => 'em space',
"\u2004" => 'three-per-em space',
"\u2005" => 'four-per-em space',
"\u2006" => 'six-per-em space',
"\u2007" => 'figure space',
"\u2008" => 'punctuation space',
"\u2009" => 'thin space',
"\u200a" => 'hair space',
"\u2028" => 'line separator',
"\u2029" => 'paragraph separator',
"\u202f" => 'narrow non-breaking space',
"\u205f" => 'medium mathematical space',
"\u3000" => 'ideographic space'
);
$db = new mysqli('localhost', 'root', '', 'crm_local');
foreach ($whitespace as $char => $name) {
$dec = json_decode('"'.$char.'"');
$test = "a{$dec}b";
$test = preg_replace('/\s+/', '', $test);
//echo "$name: a{$char}b == $test\n";
if ($test != "ab") {
echo "$char ($name) is not matched as whitespace\n";
}
$ret = $db->query("SELECT 1 FROM $dec crm_tab LIMIT 1");
if ($ret && $ret->num_rows) {
echo "$char ($name) works in query!\n";
}
}
Enable javascript to submit You have javascript disabled. You will not be able to edit any code.
Output for 8.0.0 - 8.0.30 , 8.1.0 - 8.1.28 , 8.2.0 - 8.2.18 , 8.3.0 - 8.3.6 Fatal error: Uncaught Error: Class "mysqli" not found in /in/dmdDT:30
Stack trace:
#0 {main}
thrown in /in/dmdDT on line 30
Process exited with code 255 . Output for 7.0.0 - 7.0.31 , 7.1.0 - 7.1.23 , 7.2.0 - 7.2.33 , 7.3.16 - 7.3.33 , 7.4.0 - 7.4.33 Fatal error: Uncaught Error: Class 'mysqli' not found in /in/dmdDT:30
Stack trace:
#0 {main}
thrown in /in/dmdDT on line 30
Process exited with code 255 . Output for 5.0.0 - 5.0.5 , 5.1.0 - 5.1.6 , 5.2.0 - 5.2.17 , 5.3.0 - 5.3.29 , 5.4.0 - 5.4.45 , 5.5.0 - 5.5.38 , 5.6.0 - 5.6.38 Fatal error: Class 'mysqli' not found in /in/dmdDT on line 30
Process exited with code 255 . Output for 4.3.2 - 4.3.11 , 4.4.0 - 4.4.9 Fatal error: Cannot instantiate non-existent class: mysqli in /in/dmdDT on line 30
Process exited with code 255 . Output for 4.3.0 - 4.3.1 Fatal error: Cannot instantiate non-existent class: mysqli in /in/dmdDT on line 30
preferences:dark mode live preview
286.79 ms | 401 KiB | 415 Q