Kohana -- Command Line

Posted by swt83 on Stack Overflow See other posts from Stack Overflow or by swt83
Published on 2010-01-25T15:47:00Z Indexed on 2010/04/12 4:13 UTC
Read the original article Hit count: 249

Filed under:
|

I'm trying to "faux-fork" a process (an email being sent via SMTP) in my web application, and the application is built on Kohana.

    $command = 'test/email';
    exec('php index.php '.$command.' > /dev/null/ &', $errors, $response);

I'm getting an error --

Notice: Undefined index: SERVER_NAME

When I look into Kohana's index.php file, I see that it is looking for a variable named SERVER_NAME, but I guess it is coming up NULL because Kohana couldn't detect this value and set it prior to run.

Any ideas how to get Kohana to run via command line?

© Stack Overflow or respective owner

Related posts about php

Related posts about kohana