This file contains hidden or 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 | |
| // saving habtm, many associated records at a time | |
| // Audit hasAndBelongsToMany User | |
| // table: audits_users | |
| $audit = array( | |
| 'Audit' => array( | |
| 'name' => 'My Audit', | |
| 'start_date' => '2012-02-10, |
This file contains hidden or 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
| /* | |
| * jQuery - Singleton | |
| */ | |
| var App; | |
| App = { | |
| awesomeLink: null, | |
| ready: function() { | |
| this.awesomeLink = $('#next-link'); |
This file contains hidden or 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 configuration: | |
| wildcard NameVirtualHosts and _default_ servers: | |
| *:443 atlas.brandon (/Applications/MAMP/conf/apache/extra/httpd-ssl.conf:89) | |
| Syntax OK |
This file contains hidden or 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
| ShowOffYourStash::Application.routes.draw do | |
| root :to => 'pages#home' | |
| devise_for :users do | |
| get 'dashboard' => 'users#dashboard', as: :user_root | |
| get 'users/sign_up' => 'users#new' | |
| get 'users/sign_in' => 'devise/sessions#new', as: :new_user_session | |
| post 'users/sign_in' => 'devise/sessions#create', as: :user_session | |
| get 'users/:id' => 'users#show', as: :user_profile | |
| end |
This file contains hidden or 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
| # user.rb | |
| class User | |
| include Mongoid::Document | |
| devise :database_authenticatable, :registerable, | |
| :recoverable, :rememberable, :trackable, :validatable | |
| field :username | |
| . | |
| . | |
| . |
This file contains hidden or 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.generators do |g| | |
| g.test_framework :rspec, :fixture => true, :views => false | |
| g.fixture_replacement :factory_girl, :dir => 'spec/factories' | |
| end |
This file contains hidden or 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
| createToolbar : function(editor){ | |
| var me = this, | |
| items = [], | |
| tipsEnabled = Ext.tip.QuickTipManager && Ext.tip.QuickTipManager.isEnabled(), | |
| baseCSSPrefix = Ext.baseCSSPrefix, | |
| fontSelectItem, toolbar, undef; | |
| function btn(id, toggle, handler){ | |
| return { | |
| itemId : id, |
This file contains hidden or 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
| NSString *plistPath = [[NSBundle mainBundle] pathForResource:@"Info" | |
| ofType:@"plist"]; | |
| NSFileManager *fm = [NSFileManager defaultManager]; | |
| if ([fm fileExistsAtPath:plistPath]) | |
| NSLog(@"File Exists"); | |
| else | |
| NSLog(@"File not found"); | |
| NSArray *tmpArray = [[NSArray alloc] initWithContentsOfFile:plistPath]; |
This file contains hidden or 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
| .bundle | |
| db/*.sqlite3 | |
| log/*.log | |
| tmp/ | |
| .sass-cache/ | |
| # rails ignores | |
| *.rbc | |
| *.sassc | |
| .sass-cache |
This file contains hidden or 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
| alert 'test' | |
| jQuery('.new-page').click (e) -> | |
| e.preventDefault() | |
| alert e |