This file contains 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 | |
/** | |
* @file | |
* Contains \Drupal\nv_migrate\Plugin\migrate\source\csv_club. | |
*/ | |
namespace Drupal\nv_migrate\Plugin\migrate\source; | |
use Drupal\migrate_source_csv\Plugin\migrate\source\CSV; |
This file contains 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
$url = 'https://maps.googleapis.com/maps/api/geocode/json?latlng=40.714224,-73.961452'; | |
$client = new \GuzzleHttp\Client; | |
$response = $client->get($url, [ | |
'headers' => ['Accept' => 'application/json'], | |
])->getBody(); | |
$array = json_decode($response, TRUE); | |
$iterator = new \RecursiveIteratorIterator( | |
new \RecursiveArrayIterator($array), | |
\RecursiveIteratorIterator::SELF_FIRST); | |
// Recurse through the result array. When there is an array of items at the |
This file contains 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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
This file contains 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
// ==UserScript== | |
// @name www.drupal.org | |
// @namespace tagAmsterdam2014 | |
// @match https://www.drupal.org/node/* | |
// @run-at document-end | |
// @grant none | |
// ==/UserScript== | |
// SAVE as tagAmsterdam2014.user.js | |
// Inspired by https://github.com/webflo/drupalsprint-bookmarklet/blob/gh-pages/index.html |