New WTServer Project

This is a new WTServer (wt-nmp) Project

Feel free to modify / overwrite this file!


MySql Database Connection:

Unable to connect to MySql server

			$conn=new mysqli('p:localhost');
			$conn->set_charset('utf8');
			$conn->select_db('mysql');
		

You don`t need to specify the mysql username/password, they are stored in php.ini, just like on our WTriple Hosting server


Redis Cache / NoSql Connection:

php_redis is not enabled.Add in to php.ini:
extension = php_redis.dll

			$redis=new Redis();
			$addr=empty($_SERVER['REDIS']) ? 'localhost' : $_SERVER['REDIS'];
			$redis->connect($addr);
		

This code works both locally and on our WTriple Hosting server; $_SERVER['REDIS'] specifies the Redis unix socket file


Include Test:

Include path: .:/opt/alt/php72/usr/share/pear; Including a global library file:

			include "tools/wtnmpIncludeTest.lib.php";