Skip to content

Instantly share code, notes, and snippets.

Avatar

Siddarth Chandrasekaran siddarth

View GitHub Profile
@siddarth
siddarth / gist:1379745
Created Nov 20, 2011 — forked from gdb/gist:1255035
Stripe PHP simple example
View gist:1379745
<?php
require 'path-to-Stripe.php';
if ($_POST) {
Stripe::setApiKey("YOUR-API-KEY");
$error = '';
$success = '';
try {
if (!isset($_POST['stripeToken']))
throw new Exception("The Stripe Token was not generated correctly");
You can’t perform that action at this time.