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
; site info | |
site.name = My Moustache Site | |
site.url = http://mysiteurl/ | |
; rendering vars | |
views.root = views | |
views.layout = layout | |
; session vars | |
cookies.secret = IeNj0yt0sQu33zeflUFfym0nk1e |
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 | |
require("jolt.php"); | |
include("Services/Twilio.php"); | |
$_GET['route'] = isset($_GET['route']) ? '/'.$_GET['route'] : '/'; | |
$app = new Jolt('site',false); | |
$app->option('source', 'config.ini'); | |
$client = new Services_Twilio($app->option('twilio.accountsid'), $app->option('twilio.authtoken') ); | |
$fromNumber = $app->option('twilio.fromNumber'); | |
$app->store('client',$client); |
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
curl "http://google-api-php-client.googlecode.com/files/google-api-php-client-0.6.2.tar.gz" -O | |
tar -xvf google-api-php-client-0.6.2.tar.gz |
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 | |
require_once 'google-api-php-client/src/Google_Client.php'; | |
require_once 'google-api-php-client/src/contrib/Google_CustomsearchService.php'; | |
session_start(); | |
$client = new Google_Client(); | |
$client->setApplicationName('My Google SMS Search Replacement'); | |
$client->setDeveloperKey('Your Developer Key Here'); | |
$search = new Google_CustomsearchService($client); | |
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 | |
require_once('mailer/class.phpmailer.php'); | |
$myName = "YourName"; | |
$email_pattern = "/^([a-z0-9\.\-\+\_\']+)@[a-z0-9\-\+\_]+\.[a-z0-9\-\+\_]*(\.?)[a-z0-9]+$/"; | |
$email_address = trim($_POST['Body']); | |
$email = new PHPMailer(); | |
$email->From = 'FromEmail'; | |
$email->AddReplyTo('FromEmail', $myName); | |
$email->Mailer = 'mail'; |
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 | |
function generate_uuid() { | |
return sprintf( '%04x%04x-%04x-%04x-%04x-%04x%04x%04x', | |
mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ), | |
mt_rand( 0, 0xffff ), | |
mt_rand( 0, 0x0fff ) | 0x4000, | |
mt_rand( 0, 0x3fff ) | 0x8000, | |
mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ), mt_rand( 0, 0xffff ) | |
); | |
} |
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
; site info | |
site.name = My Live Blog | |
site.url = http://mysiteurl/ | |
; rendering vars | |
views.root = views | |
views.layout = layout | |
; session vars | |
cookies.secret = IeNj0yt0sQu33zeflUFfym0nk1e |
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 | |
include("jolt.php"); | |
require 'Services/simperium.php'; | |
require 'Services/Twilio.php'; | |
require 'functions.php'; | |
$app = new Jolt(); | |
$app->option('source', 'config.ini'); |
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 | |
function slugify( $string ){ | |
$string = strtolower( trim($string) ); | |
$slug=preg_replace('/[^A-Za-z0-9-]+/', '-', $string); | |
return $slug; | |
} | |
function cropResize($img,$out='',$dSize=170){ | |
$x = @getimagesize($img); | |
$sw = $x[0]; |
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
<div class="jumbotron"> | |
<h1>Live Blog</h1> | |
</div> | |
<br /> | |
<section id="talkwrap" style="overflow: auto;margin-bottom: 10px;"> | |
<div id="talk"></div> | |
</section> | |
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script> | |
<script type="text/javascript" src="https://js.simperium.com/v0.1/"></script> | |
<script> |