Просмотр файла vkclone-0.0.1/protected/components/Worker.php
<?php Yii::import('ext.worker.AbstractWorker'); /** * Gearman worker base class * * How to create a new worker command? * public function actionReverse(WorkerJob $job) { * $job->sendComplete($job->getWorkload()); * echo strrev($job->getWorkload()); * echo "\n"; * } */ class Worker extends AbstractWorker { /** * Sets locale and path aliases */ public function init() { parent::init(); setlocale(LC_ALL, 'ru_RU.UTF-8'); } }