Skip to content

Instantly share code, notes, and snippets.

View codyjames's full-sized avatar
🐢
I will likely never set this status again.

Cody Peterson codyjames

🐢
I will likely never set this status again.
View GitHub Profile
@codyjames
codyjames / lastfmissue
Created November 8, 2011 20:34
Last.fm PHP cURL JSON
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'http://ws.audioscrobbler.com/2.0/?method=artist.getevents&artist=Josh+Harmony&api_key=d3fcabf421291d107802fce0fe2c2825&format=json');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 1);
$content = curl_exec($ch);
curl_close($ch);
$content = json_decode($content);
$events = $content->events;
@codyjames
codyjames / gist:2979464
Created June 23, 2012 18:50
CSS3 Animation Fix Glitch in Mobile Safari
// Assuming this
.foo {
-webkit-transition: -webkit-transform 1s ease-out;
}
.foo:hover {
-webkit-transform: translateX(20px);
}
<?php
// yourmodule/src/listeners/GetLinkitSchema.php
namespace modules\hshelpers\listeners;
use fruitstudios\linkit\base\Link;
use fruitstudios\linkit\models\Entry;
use markhuot\CraftQL\Types\EntryInterface;
use fruitstudios\linkit\fields\LinkitField;
use markhuot\CraftQL\Events\GetFieldSchema;