PHP code example of tristanward / laravel-workable
1. Go to this page and download the library: Download tristanward/laravel-workable 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/ */
use Tristanward\LaravelWorkable\Models\WorkableVacancy;
// Get all cached Workable vacancies
$vacancies = WorkableVacancy::all();
// Get an array of all unique vacancy locations
$locations = WorkableVacancy::uniqueLocations();
// Get an array of all unique vacancy positions
$positions = WorkableVacancy::uniquePositions();
use Tristanward\LaravelWorkable\Facades\LaravelWorkable;
// Get all published workable vacancies
$vacancies = LaravelWorkable::vacancies();
// Alternatively, a state may be provided
$vacancies = LaravelWorkable::vacancies($state = 'draft');
// Full data for a single vacancy can be accessed with it's $shortcode
$vacancy = LaravelWorkable::vacancy($shortcode = 'ABCDEFGHIJ');
php artisan migrate
php artisan laravel-workable:cache
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.