I’ve released my aircraft & fleet pages to public where you can find information about operational aircraft across the globe. The data is gathered from various sources e.g. ADS-B. It’s still under development and might change over time…
PHP check variable if consists of numbers and text
ctype_alnum($testcase);
MySQL UTC timestamp
You can insert the UTC timestamp manually as follows…
INSERT INTO table_name (utc_timestamp)
VALUES (UTC_TIMESTAMP())
Alternatively you can set the timestamp per session using…
SET @@session.time_zone='+00:00';
..or per server (my.cnf)…
[mysqld]
default_time_zone='+00:00'
PHP & how to trim, replace tabs and extra spaces with single spaces
$data = preg_replace('/[ ]{2,}|[\t]/', ' ', trim($data));
PHP & how to trim white space on beginning and the end of each new line with
$text = join("\n", array_map("trim", explode("\n", $text)));