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
class Hash | |
def recursively_symbolize_keys | |
tmp = {} | |
for k, v in self | |
tmp[k] = if v.respond_to? :recursively_symbolize_keys | |
v.recursively_symbolize_keys | |
else | |
v | |
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
// Cookie | |
var Cookie = { | |
set: function(name, value, daysToExpire) { | |
var expire = ''; | |
if (daysToExpire != undefined) { | |
var d = new Date(); | |
d.setTime(d.getTime() + (86400000 * parseFloat(daysToExpire))); | |
expire = '; expires=' + d.toGMTString(); | |
} | |
return (document.cookie = escape(name) + '=' + escape(value || '') + expire); |
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
3 # Table name: causes | |
4 # | |
5 # id :integer(4) not null, primary key | |
6 # body :text | |
7 # name :string(255) | |
8 # slug :string(255) | |
9 # created_at :datetime | |
10 # updated_at :datetime | |
11 # | |
12 |
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
504 Gateway Time-out | |
nginx/0.6.37 |
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
#!/bin/bash | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/magdalena-abakanowicz | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/michael-anderson | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/avigdor-arikha | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/l-c-armstrong | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/chakaia-booker | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/fernando-botero | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/claudio-bravo | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/grisha-bruskin | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/steven-charles |
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
#!/bin/bash | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/magdalena-abakanowicz | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/michael-anderson | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/avigdor-arikha | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/l-c-armstrong | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/chakaia-booker | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/fernando-botero | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/claudio-bravo | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/grisha-bruskin | |
ab -kc 10 -t 2 http://staging.marlboroughgallery.com/galleries/new-york/artists/steven-charles |
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
>> u = User.first | |
=> #<AdminUser id: 2, email: "[email protected]", created_at: "2009-07-27 14:19:01", updated_at: "2009-07-29 21:17:36", crypted_password: "07d8e607d131e85a6b2090030b8198c278552878e10cef07a83...", password_salt: "y6xAKXoi5I8MMhn0A5KB", persistence_token: "c9a0865f8e5b6f135d21452deeeb4019ec9483cabb3f54bdac3...", single_access_token: "EHt4OIeX6_bCCHb96u0v", perishable_token: "8GYDF4gM7drerirRuNOz", login_count: 4, failed_login_count: 0, last_request_at: "2009-07-29 21:17:36", current_login_at: "2009-07-29 21:17:27", last_login_at: "2009-07-28 15:54:27", current_login_ip: "127.0.0.1", last_login_ip: "127.0.0.1", time_zone: "Eastern Time (US & Canada)", first_name: "Jacqui", last_name: "Maher", type: "AdminUser"> | |
>> u.type = "User" | |
=> "User" | |
>> u.save | |
=> true | |
>> u | |
=> #<AdminUser id: 2, email: "[email protected]", created_at: "2009-07-27 14:19:01", updated_at: "2009-07-30 19:41:05", crypted_password: "07d8e607d131e85a6b2090030b8198c278552878e10cef07a83...", password_salt: "y6xAKXoi5I8MMhn0A5 |
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
21 describe "double tier" do | |
22 it "returns an nested unordered list" do | |
23 html = Nokogiri::HTML helper.build_new_menu(@menu_double_tier) | |
24 html.search('ul').size.should == 2 | |
25 html.search('ul#navmenu-h').size.should == 1 | |
26 html.search('ul#navmenu-h').xpath('./li').size.should == 2 | |
27 html.search('ul#navmenu-h').xpath('./li').first.xpath('./a').text.should == 'Pages' | |
28 html.search('ul#navmenu-h li ul li').size.should == 1 |
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
3 $(document).ready(function() { | |
4 $('.blue').click(function() { | |
5 console.log('in function for click on blue class'); | |
6 return false; | |
7 }); | |
8 }); |
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
⚜:~/Code $ sudo gem install assert_efficient_sql | |
Building native extensions. This could take a while... | |
ERROR: Error installing assert_efficient_sql: | |
ERROR: Failed to build gem native extension. | |
/usr/local/bin/ruby extconf.rb | |
==================== ERROR ===================== | |
Please set RUBY_SOURCE_DIR to the source path of ruby 1.8.6 (2008-08-11)! | |
================================================ |
OlderNewer