yii2-netdisk/commands/HelloController.php

31 lines
688 B
PHP
Raw Normal View History

2013-05-24 10:14:49 -04:00
<?php
/**
* @link http://www.yiiframework.com/
* @copyright Copyright (c) 2008 Yii Software LLC
* @license http://www.yiiframework.com/license/
*/
namespace app\commands;
2013-07-21 18:35:15 +04:00
2013-05-24 10:14:49 -04:00
use yii\console\Controller;
/**
* This command echoes the first argument that you have entered.
2013-05-24 10:14:49 -04:00
*
* This command is provided as an example for you to learn how to create console commands.
2013-11-27 20:19:56 +02:00
*
2013-05-24 10:14:49 -04:00
* @author Qiang Xue <qiang.xue@gmail.com>
* @since 2.0
*/
class HelloController extends Controller
{
/**
2013-07-21 11:39:32 -03:00
* This command echoes what you have entered as the message.
2013-05-24 10:14:49 -04:00
* @param string $message the message to be echoed.
*/
public function actionIndex($message = 'hello world')
{
2013-12-18 00:40:52 -05:00
echo $message . "\n";
2013-05-24 10:14:49 -04:00
}
2013-07-21 11:39:32 -03:00
}