File tree Expand file tree Collapse file tree 3 files changed +55
-0
lines changed Expand file tree Collapse file tree 3 files changed +55
-0
lines changed Original file line number Diff line number Diff line change 11# php-docker-env
22Setup nginx, mysql, memcached & ; php env by docker
3+
4+ - [ Installation] ( #installation )
5+ - [ Usage] ( #usage )
6+ - [ License] ( #license )
7+
8+
9+ Installation
10+ ------------
11+
12+ ``` bash
13+ $ git clone git@github.com:moitran/php-docker-env.git
14+ ```
15+
16+ Usage
17+ -----
18+
19+
20+ License
21+ -------
22+
23+ This source code is under [ MIT License] ( https://github.com/moitran/php-docker-env/blob/master/LICENSE )
Original file line number Diff line number Diff line change 1+ <?php
2+
3+ echo "Site1 " ;
4+ echo "</br> " ;
5+
6+ $ servername = "mysql " ;
7+ $ username = "root " ;
8+ $ password = "root " ;
9+
10+ // Create connection
11+ $ conn = new mysqli ($ servername , $ username , $ password );
12+
13+ // Check connection
14+ if ($ conn ->connect_error ) {
15+ die ("Connection mysql failed: " . $ conn ->connect_error );
16+ }
17+ echo "Connected mysql successfully " ;
Original file line number Diff line number Diff line change 1+ <?php
2+
3+ echo "Site2 " ;
4+ echo "</br> " ;
5+
6+ $ servername = "mysql " ;
7+ $ username = "root " ;
8+ $ password = "root " ;
9+
10+ // Create connection
11+ $ conn = new mysqli ($ servername , $ username , $ password );
12+
13+ // Check connection
14+ if ($ conn ->connect_error ) {
15+ die ("Connection mysql failed: " . $ conn ->connect_error );
16+ }
17+ echo "Connected mysql successfully " ;
You can’t perform that action at this time.
0 commit comments