I have created a task and i would like call a function under the execute function.
When i launch my task, i have an error :
Call to undefined function LogMess() in MyTaskTask.class.php on line ....
My script is below :
<pre>
class MyTaskTask extends sfBaseTask
{
protected function configure()
{
$this->namespace = 'Frontend';
$this->name = 'MyTask';
$this->briefDescription = 'bla bla';
$this->detailedDescription = <<<EOF
Task [SynchroID2|INFO]
Call with
[php symfony SynchroID2|INFO]
EOF;
}
function LogMess($FileLog,$typeMess,$Mess)
{
$result = fwrite($FileLog,date("Y-m-d H-i-s"
return $result;
}
protected function execute($arguments = array(), $options = array())
{
//create a log file
$fileLogP = fopen('LogFILE.LOG',"a"
// write in log file
LogMess($fileLogP ,'I',"bla bla "
{
</pre>
thank you very much
