This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE `country` ( | |
`code` CHAR(2) NOT NULL PRIMARY KEY, | |
`name` CHAR(52) NOT NULL, | |
`population` INT(11) NOT NULL DEFAULT 0 | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
INSERT INTO `country` VALUES ('AU','Australia',18886000); | |
INSERT INTO `country` VALUES ('BR','Brazil',170115000); | |
INSERT INTO `country` VALUES ('CA','Canada',1147000); | |
INSERT INTO `country` VALUES ('CN','China',1277558000); | |
INSERT INTO `country` VALUES ('DE','Germany',82164700); | |
INSERT INTO `country` VALUES ('FR','France',59225700); | |
INSERT INTO `country` VALUES ('GB','United Kingdom',59623400); | |
INSERT INTO `country` VALUES ('IN','India',1013662000); | |
INSERT INTO `country` VALUES ('RU','Russia',146934000); | |
INSERT INTO `country` VALUES ('US','United States',278357000); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE TABLE IF NOT EXISTS `catalog` ( | |
`id` int(11) NOT NULL AUTO_INCREMENT, | |
`product_name` varchar(50) NOT NULL, | |
`product_description` text NOT NULL, | |
`photo` varchar(50) DEFAULT NULL, | |
`price` float(4,2) NOT NULL, | |
PRIMARY KEY (`id`) | |
) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ; | |
-- -------------------------------------------------------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'urlManager' => [ | |
'class' => 'yii\web\UrlManager', | |
'showScriptName' => false, | |
'enablePrettyUrl' => true, | |
'rules' => array( | |
'<controller:\w+>/<id:\d+>' => '<controller>/view', | |
'<controller:\w+>/<action:\w+>/<id:\d+>' => '<controller>/<action>', | |
'<controller:\w+>/<action:\w+>' => '<controller>/<action>', | |
), | |
], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace app\controllers; | |
use yii\filters\AccessControl; | |
use yii\web\Controller; | |
class ExampleController extends Controller | |
{ | |
public function behaviors() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure("2") do |config| | |
config.vm.guest = :freebsd | |
config.vm.synced_folder ".", "/vagrant", id: "vagrant-root", disabled: true | |
config.vm.box = "freebsd/FreeBSD-10.2-STABLE" | |
config.ssh.shell = "sh" | |
config.vm.base_mac = "080027D14C66" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure(2) do |config| | |
config.vm.box = "oshpilaf/ubuntu1404-php52" | |
config.vm.network "private_network", ip: "192.168.33.10" | |
config.vm.synced_folder ".", "/var/www", owner: "www-data", group: "www-data", :mount_options => ["dmode=777", "fmode=666"] | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# All Vagrant configuration is done below. The "2" in Vagrant.configure | |
# configures the configuration version (we support older styles for | |
# backwards compatibility). Please don't change it unless you know what | |
# you're doing. | |
Vagrant.configure(2) do |config| | |
# The most common configuration options are documented and commented below. | |
# For a complete reference, please see the online documentation at |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# All Vagrant configuration is done below. The "2" in Vagrant.configure | |
# configures the configuration version (we support older styles for | |
# backwards compatibility). Please don't change it unless you know what | |
# you're doing. | |
Vagrant.configure(2) do |config| | |
config.vm.box = "myopensoft/devbox" | |
config.vm.network "private_network", ip: "192.168.33.10" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<web-app xmlns="http://java.sun.com/xml/ns/javaee" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" | |
version="2.5"> | |
<filter> | |
<filter-name>UrlRewriteFilter</filter-name> | |
<filter-class>org.tuckey.web.filters.urlrewrite.UrlRewriteFilter</filter-class> | |
</filter> | |
<filter-mapping> |
OlderNewer