A Pen by Joshua Pike on CodePen.
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
<? | |
function make_request($url) { | |
$ch = curl_init(); | |
curl_setopt($ch, CURLOPT_URL, $url); | |
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); | |
$clientResponse = curl_exec($ch); |
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 | |
namespace App\Auth; | |
use Cake\Auth\BaseAuthenticate; | |
use Cake\Network\Request; | |
use Cake\Network\Response; | |
use Cake\Core\Configure; | |
use Cake\Event\Event; | |
use Cake\Network\Session; |
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 | |
$endupload = "up"; | |
class phpVimeo | |
{ | |
const API_REST_URL = 'http://vimeo.com/api/rest/v2'; | |
const API_AUTH_URL = 'http://vimeo.com/oauth/authorize'; | |
const API_ACCESS_TOKEN_URL = 'http://vimeo.com/oauth/access_token'; | |
const API_REQUEST_TOKEN_URL = 'http://vimeo.com/oauth/request_token'; |
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 | |
/** | |
* Title | |
* | |
* Description | |
* Description | |
* Description | |
* | |
* @author Fabio |
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 | |
/** | |
* Class Person | |
* @Table people | |
*/ | |
class Person | |
{ | |
/** | |
* @Prop Yep | |
*/ |
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
nametrans = lambda folder: {'[Gmail]/Drafts': 'drafts', | |
'[Gmail]/Sent Mail': 'sent', | |
'[Gmail]/Starred': 'flagged', | |
'[Gmail]/Trash': 'trash', | |
'[Gmail]/All Mail': 'archive', | |
}.get(folder, folder) |
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/bash | |
set -e | |
err_report() { | |
echo "There was an issue with one of the pre-commit hooks" | |
echo ".git/hooks/pre-commit-*" | |
echo "Error on line $1" | |
} | |
trap 'err_report $LINENO' ERR |
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
# This script generates mkdocs friendly Markdown documentation from a python package. | |
# It is based on the the following blog post by Christian Medina | |
# https://medium.com/python-pandemonium/python-introspection-with-the-inspect-module-2c85d5aa5a48#.twcmlyack | |
import pydoc | |
import os, sys | |
module_header = "# Package {} Documentation\n" | |
class_header = "## Class {}" | |
function_header = "### {}" |
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 | |
class Google_OAuth { | |
var $client_id; | |
var $client_secret; | |
var $redirect_uri; | |
var $scopes = array( | |
'userinfo' => array( |