This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| use Illuminate\Database\Eloquent\Builder | |
| Builder::macro('toSqlWithBindings', function(){ | |
| $bindings = array_map(function($value){ | |
| return is_numeric($value) ? $value : "'{$value}'"; | |
| }, $this->getBindings()); | |
| return Str::replaceArray('?', $bindings, $this->toSql()); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| # Update the "documentroot" value to the new path in the following files | |
| sed -i -e 's/public_html/public_html\/public/g' /var/cpanel/userdata/$1/$2 | |
| # Update the "documentroot" value to the new path in the following files | |
| sed -i -e 's/public_html/public_html\/public/g' /var/cpanel/userdata/$1/$2_SSL | |
| # Remove the existing cache files | |
| rm -f /var/cpanel/userdata/$1/$2.cache |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| if (!function_exists('now')) { | |
| function now() | |
| { | |
| return new class() | |
| { | |
| protected $now; | |
| protected $defaultFormat = 'd.m.Y H:i:s'; |
NewerOlder