PHP code example of gts-meghni / laravel-essentials-kit
1. Go to this page and download the library: Download gts-meghni/laravel-essentials-kit 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/ */
gts-meghni / laravel-essentials-kit example snippets
$code = app(OtpStore::class)->issue($user->phone); // send this yourself
app(OtpStore::class)->verify($user->phone, $request->string('code')->toString());
php artisan migrate
php artisan db:seed --class=AlgeriaGeoSeeder
Province::where('code', '16')->first()->translatedName(); // "الجزائر" under the ar locale
$commune->translatedName('fr');
$province->communes;
if ($this->app->environment('local') && class_exists(\Laravel\Telescope\TelescopeServiceProvider::class)) {
$this->app->register(\Laravel\Telescope\TelescopeServiceProvider::class);
$this->app->register(TelescopeServiceProvider::class);
}
new OA\Response(
response: 422,
description: 'The request was invalid.',
content: new OA\JsonContent(ref: '#/components/schemas/ValidationErrorResponse'),
),