diff --git a/database/cloud-server.mwb b/database/cloud-server.mwb new file mode 100644 index 0000000..5343626 Binary files /dev/null and b/database/cloud-server.mwb differ diff --git a/src/application/controller/index.php b/src/application/controller/index.php new file mode 100644 index 0000000..aa42257 --- /dev/null +++ b/src/application/controller/index.php @@ -0,0 +1,3 @@ +db = new PDO('mysql:dbname=' . $database . ';host=' . $hostname . ';port=' . $port . ';charset=utf8', $user, $password, [PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES utf8']); + $this->db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); + $this->db->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_ASSOC); + } catch(PDOException $e) { + trigger_error($e->getMessage()); + } + } +} \ No newline at end of file diff --git a/src/application/view/index.phtml b/src/application/view/index.phtml new file mode 100644 index 0000000..e69de29 diff --git a/src/bootstrap.php b/src/bootstrap.php new file mode 100644 index 0000000..dd4ab01 --- /dev/null +++ b/src/bootstrap.php @@ -0,0 +1,5 @@ + 4 && ($number % 100) < 20) ? 2 : $cases[min($number % 10, 5)]]; +} \ No newline at end of file