Valet switch PHP version with these commands
Install PHP 5.6 and switch Valet to PHP 5.6
valet stop
brew unlink php71
brew install php56
brew install php56-mcrypt
brew link php56
valet start
| /** | |
| * Retrieves all the rows in the active spreadsheet that contain data and logs the | |
| * values for each row. | |
| * For more information on using the Spreadsheet API, see | |
| * https://developers.google.com/apps-script/service_spreadsheet | |
| */ | |
| function readRows() { | |
| var sheet = SpreadsheetApp.getActiveSheet(); | |
| var rows = sheet.getDataRange(); | |
| var numRows = rows.getNumRows(); |
Valet switch PHP version with these commands
Install PHP 5.6 and switch Valet to PHP 5.6
valet stop
brew unlink php71
brew install php56
brew install php56-mcrypt
brew link php56
valet start
| alias gl="git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit" |
| $dt=new DateTime;$model->created_at=$dt->format('m-d-y H:i:s'); | |
| /* | |
| * This block of code could be added to your models (or you can create a new model which contains these and extend from your | |
| * model. Each section will make sure the created_at and updated_at timestamp fields are updated in the database. | |
| */ | |
| class YourModel extends Eloquent.... | |
| public $timestamps = false; |
| <?php | |
| namespace App\Http\Middleware; | |
| use Closure; | |
| class RewriteLinks | |
| { | |
| /** | |
| * Handle an incoming request. |
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <script src="https://fb.me/react-with-addons-0.14.7.min.js"></script> | |
| <script src="https://fb.me/react-dom-0.14.7.min.js"></script> | |
| <meta charset="utf-8"> | |
| <meta name="viewport" content="width=device-width"> | |
| <title>JS Bin</title> | |
| <style id="jsbin-css"> | |
| body { |
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <script src="https://fb.me/react-with-addons-0.14.7.min.js"></script> | |
| <script src="https://fb.me/react-dom-0.14.7.min.js"></script> | |
| <meta charset="utf-8"> | |
| <meta name="viewport" content="width=device-width"> | |
| <title>JS Bin</title> | |
| <style id="jsbin-css"> | |
| body { |
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <script src="http://vuejs.org/js/vue.js"></script> | |
| <meta charset="utf-8"> | |
| <title>JS Bin</title> | |
| <style id="jsbin-css"> | |
| .container { | |
| display: flex | |
| } |
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"> | |
| <title>JS Bin</title> | |
| <style id="jsbin-css"> | |
| .grid { | |
| border: 3px solid black; | |
| } |
| <snippet> | |
| <content><![CDATA[ | |
| // ${1} Resource | |
| Route::get('${1}s', array('as' => '${1}s', 'uses' => '${1}s@index')); | |
| Route::get('${1}s/(:any)', array('as' => '${1}', 'uses' => '${1}s@show')); | |
| Route::get('${1}s/new', array('as' => 'new_${1}', 'uses' => '${1}s@new')); | |
| Route::get('${1}s/(:any)edit', array('as' => 'edit_${1}', 'uses' => '${1}s@edit')); | |
| Route::post('${1}s', '${1}s@create'); | |
| Route::put('${1}s/(:any)', '${1}s@update'); | |
| Route::delete('${1}s/(:any)', '${1}s@destroy'); |