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 Channel < ActiveRecord::Base | |
attr_accessible :private, :title, :color_code, :subscriptions_attributes | |
validates_presence_of :user, :title | |
after_save :add_owner | |
belongs_to :user | |
has_many :subscriptions, :inverse_of => :channel, :dependent => :destroy | |
has_many :users, :through => :subscriptions, :uniq => true | |
accepts_nested_attributes_for :subscriptions, :allow_destroy => true |
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
<!--[if lte IE 8]> | |
<meta http-equiv="refresh" content="0; url=/ie_unsupported.html" /> | |
<script type="text/javascript"> | |
/* <![CDATA[ */ | |
window.top.location = '/ie_unsupported.html'; | |
/* ]]> */ | |
</script> | |
<![endif]--> |
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
<VirtualHost *:80> | |
ServerAdmin david.stites@afewguyscoding.com | |
ServerName afewguyscoding.com | |
ServerAlias www.afewguyscoding.com, davidstites.com, www.davidstites.com, 5280software.com, www.5280software.com, milehigh-software.com, www.milehigh-software.com, milehighsoftware.org, www.milehighsoftware.org, | |
# this tells rails that it will run in production mode | |
# this is for rails < 3.x | |
RailsEnv production | |
DocumentRoot /var/www/afewguyscoding/current/public |
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
$(document).ready(function() { | |
// ... | |
$('.selector_control').live('click', function() { | |
$(this).parents('.select_galleries').find('.select_photos').slideToggle(); | |
}); | |
$('.all_photos').click(function(){ | |
$(this).closest('.select_galleries').find("INPUT[type='checkbox']").attr('checked', true); | |
}); |