1. Go to this page and download the library: Download jrsaunders/quickasync library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
jrsaunders / quickasync example snippets
use QuickAsync\Setup;
Setup::setBasePath( '/var/www/vhost/some/dir/async' );
class Async extends MyApp {
public function run( $asyncFile = null ) {
if ( isset( $asyncFile ) ) {
$queueItem = new \QuickAsync\QueueItem( $asyncFile );
$asyncData = $queueItem->getObject();
$queueItem->run( $this );
}
}
}
use QuickAsync\Item;
class CoolClass extends MyApp(){
public function somethingCool($name,$carName){
//save this car to my name or something like that do some complicated processing.....
return $importantData;
}
public function triggerAsyncProcess(){
$asyncItem = new Item($this,'CoolClass','somethingCool',['John','Lamborghini'],__FILE__);
asyncItem->queue();
}
}
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.