PHP code example of in2pire / cli
1. Go to this page and download the library: Download in2pire/cli library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
in2pire / cli example snippets
#!/usr/bin/env php
/**
* Memcached CLI Application
*/
if (PHP_SAPI !== 'cli') {
echo 'Warning: memcached-cli should be invoked via the CLI version of PHP, not the ' . PHP_SAPI . ' SAPI' . PHP_EOL;
exit(1);
}
define('APP_NAME', 'memcached-cli');
define('APP_PATH', __DIR__);
define('APP_CONF_PATH', APP_PATH . '/../conf/' . APP_NAME);
// Add class loader.