Skip to content

Instantly share code, notes, and snippets.

->orderBy(\DB::raw('-`sortOrder`'), 'desc')->get();
@sikrew
sikrew / AppServiceProvider.php
Last active November 23, 2018 12:29
Are you getting the error: "The Mix manifest does not exist" when the file exists? Try rebinding the public path.
/**
| Upon getting this error on a production environment in which you cant install `npm` to run
| `run npm dev` or `run npm production` to compile the assets, you can add this to the `boot()` method of your `AppServiceProvider.php`
| to bind a new path to the existing manifest of your application.
*/
//...
/**
@sikrew
sikrew / ulLiTree.php
Last active March 28, 2016 15:04
ul li tree generator function
<?php
$tree = array(
'Parent' => array(
'Children 1' => array(
'1\'s Child 1',
'1\'s Child 2',
'1\'s Child 3'
),
'Children 2' => array(
'2\'s Child 1',