1. Go to this page and download the library: Download phpdominicana/lightwave 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/ */
phpdominicana / lightwave example snippets
$app->get('hello', new Route('/hello/{name}', ['_controller' => [HelloController::class, 'index']]));
$app->get('home',
new Route(
'/',
[
'_controller' => [HomeController::class, 'index'],
'container' => new Psr11Container($app->getInjector())
]
)
);
$app->post('create_user',
new Route(
'/users',
[
'_controller' => [UserController::class, 'store'],
'container' => new Psr11Container($app->getInjector())
]
)
);
namespace Phpdominicana\Lightwave\Models;
use Illuminate\Database\Eloquent\Model;
class User extends Model
{
protected $table = 'users';
protected $fillable = ['name', 'email', 'password'];
}
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.