This gist is part of a blog post. Check it out at:
http://jasonrudolph.com/blog/2011/08/09/programming-achievements-how-to-level-up-as-a-developer
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Kitten!</title> | |
<meta charset="utf-8" /> | |
<script type="text/javascript"> | |
var xhr = new XMLHttpRequest(); | |
xhr.open('GET', 'http://example.com/images/kitten.jpg', true); | |
Imports Microsoft.Web.Infrastructure.DynamicModuleHelper | |
Imports Ninject | |
Imports Ninject.Web.Mvc | |
<Assembly: WebActivator.PreApplicationStartMethod(GetType(applicationName.App_Start.NinjectMVC3), "StartNinject")> | |
<Assembly: WebActivator.ApplicationShutdownMethodAttribute(GetType(applicationName.App_Start.NinjectMVC3), "StopNinject")> | |
Namespace applicationName.App_Start | |
Public Module NinjectMVC3 | |
Private ReadOnly bootstrapper As New Bootstrapper() |
namespace Example | |
{ | |
public class ContactData | |
{ | |
public string Name { get; set; } | |
public string Email { get; set; } | |
public string Comment { get; set; } | |
} | |
} |
This gist is part of a blog post. Check it out at:
http://jasonrudolph.com/blog/2011/08/09/programming-achievements-how-to-level-up-as-a-developer
var item = new ImportantShopItem | |
{ | |
Name = "נעליים", | |
Image = @"alk/hdsbnduaisgbdy8dca89sa7d8yhas79dghyigbiy=", | |
ItemNameEng = "Shoes", | |
Class = "Footware", | |
Group = "GroupName", | |
Price = 12.87, | |
Optional = new Dictionary<string, dynamic> | |
{ |
def test_add_items | |
assert_equal 0, @list.items.size | |
@list.add_item(@item) | |
assert_equal 1, @list.items.size | |
end |
Your theme must "support" sharing and you must enable sharing in the settings otherwise it won't display that block | |
{block:Sharing} | |
... | |
<li class="bitorama-share-button"> | |
<a href="https://bitorama.com/submit?title={Title}&url={Permalink}" target="_blank"> <img src="https://bitorama.com/images/buttons/submit_wide_16.png" alt="להוסיף לביטורמה"border="0" /> </a> | |
</li> | |
... | |
{/block:Sharing} |
public static class MvcMockHelpers | |
{ | |
public static HttpContextBase FakeHttpContext() | |
{ | |
var context = new Mock<HttpContextBase>(); | |
var request = new Mock<HttpRequestBase>(); | |
var response = new Mock<HttpResponseBase>(); | |
var session = new Mock<HttpSessionStateBase>(); | |
var server = new Mock<HttpServerUtilityBase>(); |
16:46:41 web.1 | ERROR:root:Uncaught exception GET /css/streetcode.css (127.0.0.1) | |
16:46:41 web.1 | HTTPRequest(protocol='http', host='localhost:5000', method='GET', uri='/css/streetcode.css', version='HTTP/1.1', remote_ip='127.0.0.1', body='', headers={'Connection': 'keep-alive', 'Accept-Language': 'ru', 'Accept-Encoding': 'gzip, deflate', 'Cookie': 'csrftoken=811fbb57a02e031bf3558b124e5d60cd', 'Host': 'localhost:5000', 'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', 'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/534.50 (KHTML, like Gecko) Version/5.1 Safari/534.50'}) | |
16:46:41 web.1 | Traceback (most recent call last): | |
16:46:41 web.1 | File "/Users/stanislav/Heroku/Streetcode/lib/python2.7/site-packages/tornado/web.py", line 954, in _execute | |
16:46:41 web.1 | getattr(self, self.request.method.lower())(*args, **kwargs) | |
16:46:41 web.1 | TypeError: get() takes at least 2 arguments (1 given) | |
16:46:41 web.1 | ERROR:root:500 G |
#!/usr/bin/env python | |
# | |
# Vkontatke OAuth 2.0 wrapper | |
# Copyright 2011, Adil Khashtamov [[email protected]] | |
# http://khashtamov.kz | |
# | |
# | |
import logging |