李德康 李德康 - 1 month ago 8
Bash Question

How to call a public static member method(PHP Class) through the Shell Script?And what is the "phpr"?

I have read a shell script:

#!/bin/bash
function do_export{

phpr Job_Sync_Third > /tmp/Job_Sync_Topoc.log 2>/dev/null

}

do_export


This code is to call the main functin of a class(Job_Sync_Third). I found this class throungh the "grep -rnw -e" command.

The Following is the class:

require_once(xxxx);
class Job_Sync_Third
{
protected $__config = array();
public function run () {}
static public function main()
{
$job = new Job_Sync_Third();
$job->run();
}
}


The "phpr" calls the static method in the Job_Sync_Third. It is being installed below the "/usr/bin" directory.
How did it do it in a shell script calls the static member function of the class?And what is the "phpr"? I can't get any useful information from Google.

Answer

The "phpr" maybe is a parser of the author compile.

Comments