Skip to content

Instantly share code, notes, and snippets.

View djones's full-sized avatar
🍍
' OR '1'='1

David Jones djones

🍍
' OR '1'='1
View GitHub Profile
@djones
djones / gist:702473
Created November 16, 2010 20:40
Refinery CMS Wiki Article
{{Infobox software
| name = Refinery CMS
| logo = [[File:Refinery-cms-logo.png]]
| screenshot = [[File:Dashboard-2.png|400px|Screenshot]]
| caption =
| collapsible =
| developer = [[David Jones (Software Developer)|David Jones]], [[Philip Arndt (Software Developer)|Philip Arndt]]. [[Resolve Digital (Web Firm)|Resolve Digital]]
| released = {{Start date|2009|5}}
| discontinued =
| latest release version = 0.9.8.5
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
http://developer.apple.com/library/safari/documentation/AppleApplications/Reference/SafariHTMLRef/Articles/MetaTags.html
#import <AVFoundation/AVFoundation.h>
@interface Player : NSObject <AVAudioPlayerDelegate> {
AVAudioPlayer *_audioPlayer;
BOOL preloading;
}
@property (nonatomic) BOOL preloading;
- (void)playSound:(NSString *)soundName ofType:(NSString *)type;
@djones
djones / gist:720667
Created November 29, 2010 21:35
4 views in Refinery that are hardcoded
rendering a custom plugin
<section id='body_content'>
<h1><%= @destination.title %></h1>
<section id='page_body'>
<section>
<h1>Choose from our most popular recommended itineraries below</h1>
</section>
<%= render @destination.trips %>
@djones
djones / gist:720668
Created November 29, 2010 21:36
4 views in Refinery that use the current _content_page partial
rendering a custom plugin
<% content_for :page_title do %>
<%= @destination.title %>
<% end %>
<% content_for :page_body do %>
<section>
<h1>Choose from our most popular recommended itineraries below</h1>
</section>
@djones
djones / gist:720672
Created November 29, 2010 21:37
4 views in Refinery that use a new type of content_page
rendering a custom plugin
<% content_for :page_title do %>
<%= @destination.title %>
<% end %>
<% content_for :page_body do %>
<section>
<h1>Choose from our most popular recommended itineraries below</h1>
</section>
@djones
djones / gist:1032852
Created June 18, 2011 06:09
Improves the readability on Ryan's blog
article {
color: #AAA;
}
body {
line-height: 195%;
font-size: 16px;
background: #333;
}
@djones
djones / gist:2333134
Created April 8, 2012 00:31
Feedback regarding Refinery CMS
An email exchange regarding Refinery CMS
----------------------------------------
#1 Inquiry received on the Resolve Digital website
From: X
Email: X
I really cannot stop wondering how can you even dare to call something
like Refinery "a CMS". It amazes me even more that you combine that with
@djones
djones / coffee_hydration.rb
Created April 19, 2012 16:27
Does my coffee hydrate or dehydrate me?
# Do you hydrate or dehydrate your body when having a coffee?
# Constants based on references below
MG_OF_CAFFEINE_PER_SHOT = 77 # mg
SHOT_VOLUME = 44 # ml
WATER_PERCENT_IN_MILK = 87 # %
WATER_LOSS_FROM_CAFFEINE = 1.17 # ml/mg
# number_of_shots : standard single shot
# size_of_cup : in ml
@djones
djones / gist:2596822
Created May 4, 2012 18:38
Sudocode on how I would like Grape to work with Goliath
# Sudocode on how I would like grape to work with Goliath
# http://localhost:9000/randomuser #=> random user in json
require 'goliath'
require 'grape'
require 'em-synchrony/activerecord'
class User < ActiveRecord::Base
end