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
#!/usr/bin/python | |
# -*- coding: utf-8 -*- | |
# Copyright 2008 Ryan Cox ( ryan.a.cox@gmail.com ) All Rights Reserved. | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 |
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
from django.http import Http404, HttpResponse, HttpResponsePermanentRedirect | |
from django.template import RequestContext, loader | |
from django.shortcuts import render_to_response | |
def index(request): | |
cxt = {} | |
return render_to_response('main/index.html', | |
cxt, context_instance=RequestContext(request)) |
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
function levenshtein(s1, s2) { | |
// http://kevin.vanzonneveld.net | |
// + original by: Carlos R. L. Rodrigues (http://www.jsfromhell.com) | |
// + bugfixed by: Onno Marsman | |
// + revised by: Andrea Giammarchi (http://webreflection.blogspot.com) | |
// + reimplemented by: Brett Zamir (http://brett-zamir.me) | |
// + reimplemented by: Alexander M Beedie | |
// * example 1: levenshtein('Kevin van Zonneveld', 'Kevin van Sommeveld'); | |
// * returns 1: 3 |
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
// best if ran from a console debugger in firefox(firebug) / chrome(jsdebugger) | |
var str = 'market_cap;min=340,max=400,pe_ratio;min=4,max=23,div_yield;min=3.00,max=6.00'; | |
str.match(/[a-z_]+;([a-z0-9=.]+,?){2}/g); | |
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
""" | |
jQuery templates use constructs like: | |
{{if condition}} print something{{/if}} | |
This, of course, completely screws up Django templates, | |
because Django thinks {{ and }} mean something. | |
Wrap {% verbatim %} and {% endverbatim %} around those | |
blocks of jQuery templates and this will try its best |
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
.wordwrap { | |
white-space: pre-wrap; /* CSS3 */ | |
white-space: -moz-pre-wrap; /* Firefox */ | |
white-space: -pre-wrap; /* Opera <7 */ | |
white-space: -o-pre-wrap; /* Opera 7 */ |
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
http://askubuntu.com/questions/64765/i-downloaded-dwarf-fortress-why-wont-it-run | |
http://www.bay12forums.com/smf/index.php?topic=66142.315 | |
sudo apt-get install libsdl1.2debian libsdl-image1.2 libsdl-ttf2.0-0 |
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
" enable pathogeon plugin | |
call pathogen#infect() | |
" begin the great vim setup | |
set t_Co=256 | |
set term=screen-256color | |
set autoindent | |
set ruler | |
set smarttab | |
set number |
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
abaci.io | |
aback.io | |
abaft.io | |
abase.io | |
abash.io | |
abate.io | |
abbe.io | |
abbess.io | |
abbey.io | |
abbot.io |
OlderNewer