Skip to content

Instantly share code, notes, and snippets.

View shanaver's full-sized avatar

Bryan Shanaver shanaver

View GitHub Profile
@shanaver
shanaver / corporate.html
Created June 25, 2015 18:29
Donately form.js Corporate Matching Example
<html>
<head>
<title>Corporate Matching</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script type="text/javascript">
$(function()
{
$('#company').change(create_form)
<!DOCTYPE html>
<html>
<head>
<title>Donately Progress Bar Widget</title>
<script type="text/javascript">
/********
*
@shanaver
shanaver / formjs.html
Last active August 29, 2015 14:08
iFrame form.js for sites like WIX
<iframe class="donately-donation-iframe" frameborder="0" allowtransparency="true" style="background-color: transparent; border: 0px none transparent; overflow: hidden; display: inline-block; visibility: visible; margin: 0px; padding: 0px; height: 540px; width: 100%;" src="https://www.dntly.com/js/v1/form-inner?donately_id=198"></iframe>
@shanaver
shanaver / form-background-styles.css
Created October 14, 2014 17:54
Donately form.js custom background styles
/* ==========================================================================
DONATELY
========================================================================== */
@import url(http://fonts.googleapis.com/css?family=Open+Sans);
.donately-donation-form {
background-color: #446E82;
padding: 4px;
}
@shanaver
shanaver / form-submit-styles.css
Created October 14, 2014 17:54
Donately form.js custom submit button styles
/* ==========================================================================
DONATELY
========================================================================== */
@import url(http://fonts.googleapis.com/css?family=Open+Sans);
.donately-btn.donately-submit {
border: none;
background-image: none;
background-color: #239BE0;
@shanaver
shanaver / formjs-custom-css.html
Created October 14, 2014 17:49
Donately Form.js Custom Background Color & More
<!DOCTYPE html>
<html>
<head>
<title>test</title>
<style type="text/css">
body {
background-color: #446E82;
}
.formbox{
width: 400px;
### Keybase proof
I hereby claim:
* I am shanaver on github.
* I am shanaver (https://keybase.io/shanaver) on keybase.
* I have a public key whose fingerprint is CD79 00D0 8D50 3A69 78B7 8F82 61D0 B03E 0FBE A721
To claim this, I am signing this object:
@shanaver
shanaver / donately-recurring-default.html
Last active August 29, 2015 14:06
Setting the recurring option by default
<!DOCTYPE html>
<html>
<head>
<title>test</title>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script type="text/javascript">
jQuery( window ).load(function() {
jQuery('#donately-one-time-donation').prop('checked', false);
jQuery('#donately-recurring-donation').prop('checked', true);
});
@shanaver
shanaver / rackspace.v2.accept
Created August 20, 2014 21:26
Accepta a shard image via the Rackspace v2 API
curl -X PUT https://dfw.images.api.rackspacecloud.com/v2.0/images/$image_id/members/$account_two_id \
-H "X-Auth-Token: $account_two_api_token" \
-H "Content-Type: application/openstack-images-v2.1-json-patch" \
-d '{"status": "accepted"}' \
| python -m json.tool
@shanaver
shanaver / rackspace.v2.addMember
Created August 20, 2014 21:20
Share an image via the Rackspace v2 API
curl -X POST https://dfw.images.api.rackspacecloud.com/v2.0/images/$image_id/members \
-H "X-Auth-Token: $account_one_api_token" \
-H "Content-Type: application/openstack-images-v2.1-json-patch" \
-d '{"member": "$account_two_id"}' \
| python -m json.tool