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
module CarrierWave | |
module FFMPEG | |
extend ActiveSupport::Concern | |
module ClassMethods | |
def faststart | |
process :faststart => true | |
end | |
def transcode options |
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
class ArtistsController < ApplicationController | |
def create_bid | |
#this is where we delete the images array so that we can | |
#add them to the model separately afterwards | |
bids = params[:art_bid].delete(:bid_images) | |
@artist = Artist.find(params[:id]) | |
@art_bid = ArtBid.new(params[:art_bid]) |
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
// JSON Array of Towns.. In Rails: <%= @towns = Town.all.to_json %> | |
var TOWNS = [ | |
{ town: "Abbeville city", id: 1 }, | |
{ town: "Adamsville city", id: 2 }, | |
{ town: "Addison Town", id: 3 } | |
]; | |
$(document).ready(function() { | |
$('#postcard_city').bind('change', updateStateValue); |
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
// JSON Array of Towns.. In Rails: <%= @towns = Town.all.to_json %> | |
var TOWNS = [ | |
{ town: "Abbeville city", id: 1 }, | |
{ town: "Adamsville city", id: 2 }, | |
{ town: "Addison Town", id: 3 } | |
]; | |
$(document).ready(function() { | |
$('#postcard_city').bind('change', updateStateValue); |
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
$('#nameOfDivId').on('change', function(event){ | |
if($(this).width() > 100%) | |
//remove it | |
}); |
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 | |
date_default_timezone_set('America/New_York'); | |
echo "America/New_York time: ".time(); | |
date_default_timezone_set('UTC'); | |
echo "UTC Time: ".time(); | |
?> |
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
# config.ru for Pow + Wordpress, based on http://stuff-things.net/2011/05/16/legacy-development-with-pow/ | |
# added hackery to work around wordpress issues - Patrick Anderson ([email protected]) | |
# added rubygems, replaced script_path with script from path_parts, added to_return to fix return error - Paul Cook | |
# clearly this could be cleaner, but it does work | |
# added rewrite rule for WordPress Multi Site - Per Soderlind (see also http://soderlind.no/archives/2012/12/02/wordpress-and-pow/) | |
require 'rubygems' | |
require 'rack' | |
require 'rack-legacy' | |
require 'rack-rewrite' |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Box Shadow</title> | |
<style> | |
.box { | |
height: 150px; | |
width: 300px; | |
margin: 20px; |
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
********* SCSS STYLING ********** | |
.dropdown-list { | |
border: 1px solid #ddd; | |
max-width: 600px; | |
width: 100%; | |
margin: 15px auto; | |
background: #FFF; | |
height: 36px; | |
overflow: hidden; |
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
# -*- coding: utf-8 -*- | |
$:.unshift("/Library/RubyMotion/lib") | |
require 'motion/project/template/osx' | |
Motion::Project::App.setup do |app| | |
# Use `rake config' to see complete project settings. | |
app.name = 'MenubarApp' | |
app.info_plist['NSUIElement'] = 1 | |
end |
OlderNewer