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(); |
| <nav class="navbar navbar-expand-md navbar-dark bg-dark fixed-top"> | |
| <a class="navbar-brand" href="#">Navbar</a> | |
| <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarsExampleDefault" aria-controls="navbarsExampleDefault" aria-expanded="false" aria-label="Toggle navigation"> | |
| <span class="navbar-toggler-icon"></span> | |
| </button> | |
| <div class="collapse navbar-collapse" id="navbarsExampleDefault"> | |
| <ul class="navbar-nav mr-auto"> | |
| <li class="nav-item active"> | |
| <a class="nav-link" href="#">Home <span class="sr-only">(current)</span></a> |
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 { |
| // requires an array sorted in ascending order | |
| var possibleCombinationSum = function(arr, n) { | |
| // easiest case: n is in the array somewhere | |
| if (arr.indexOf(n) >= 0) { return true; } | |
| // if the smallest element is > n, no solution, so finish | |
| if (arr[0] > n) { return false; } | |
| // get rid of any elements larger than n, recursively | |
| if (arr[arr.length - 1] > n) { | |
| arr.pop(); |
| <!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 | |
| } |