composer refresh autoload code example
Example 1: composer install without dependencies
composer install --ignore-platform-reqs
Example 2: composer autoload
require __DIR__ . '/vendor/autoload.php';
$log = new Monolog\Logger('name');
$log->pushHandler(new Monolog\Handler\StreamHandler('app.log', Monolog\Logger::WARNING));
$log->addWarning('Foo');
Example 3: upgrade composer
To update composer command just find location of composer.phar and update as:
where composer
cd path_to_composer.phar
php composer.phar self-update