Skip to content

Instantly share code, notes, and snippets.

View makotoworld's full-sized avatar
😉
Happy Coding!

nzk makotoworld

😉
Happy Coding!
View GitHub Profile
#!/usr/bin/perl
# deaf_blog_yahoo_api.pl
use strict;
use warnings;
use WebService::Simple;
use WebService::Simple::Parser::JSON;
use Perl6::Say;
use Data::Dumper;
@makotoworld
makotoworld / DeafNewsJp Python
Created August 6, 2010 08:05
DeafNewsJp Python
import datetime
from google.appengine.ext import db
from google.appengine.api import users
class Deafnewsdb(db.Model):
keyword = db.StringProperty(required=True)
title = db.StringProperty(required=True)
url = db.StringProperty(required=True)
bitly_url = db.StringProperty(required=True)
publisher = db.StringProperty(required=True)
@makotoworld
makotoworld / Django1.3.1 インストール+テスト
Created December 6, 2011 06:32
apache2.2 + python2.7 + mod_wsgi3.3 + Django1.3.1環境構築メモ
pip install django
cd /home/xxxx/htdocs/
dajango-admin.py startproject mysite
cd mysite
mkdir templates
vim setting.py
db の設定
テンプレートの場所の設定
@makotoworld
makotoworld / index.html
Created December 7, 2011 06:40
deaf_informaiton
<!DOCTYPE html>
<html lang="ja">
<head>
<meta charset="utf-8">
<title>Deaf Information</title>
<meta name="description" content="">
<meta name="author" content="">
<!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
<!--[if lt IE 9]>
@makotoworld
makotoworld / めも
Created December 7, 2011 08:34
mail
djb
mail qmail
mailing list fml,ezmlm
@makotoworld
makotoworld / random_key.py
Created December 12, 2011 07:09
9桁のランダムなキーを生成(A-Za-z0-9)
# coding: utf-8
import random
import string
def random_key():
if __name__ == "__main__":
message = string.ascii_lowercase + string.ascii_uppercase + string.digits
random_message = "".join([message[random.randrange(0, len(message)-1)] for cnt in range(9)])
print random_message
@makotoworld
makotoworld / maps_geocoding.html
Created December 14, 2011 08:14
Googlemaps住所
http://hampom.humming-code.com/google-map-api-v3/
http://hampom.wordpress.com/2010/03/03/google-maps-apiv3-%E3%81%A7%E4%BD%8F%E6%89%80%E3%81%8B%E3%82%89%E5%9C%B0%E5%9B%B3%E3%81%AB%E3%83%9E%E3%83%BC%E3%82%AB%E3%83%BC%E3%82%92%E7%BD%AE%E3%81%8F%EF%BC%81/
@makotoworld
makotoworld / gist:1681764
Created January 26, 2012 08:32
Django でiCalカレンダーを生成する
https://github.com/statesofpop/django-cal
import vobject.iCalender
def ical(user_id=None):
cal = vobject.iCalendar()
cal.add('method').value = 'PUBLISH'
cal.add('calscale').value = 'GREGORIAN'
cal.add('x-wr-calname').value = 'TestCal28'
cal.add('x-wr-timezone').value = 'Australia/Sydney'
@makotoworld
makotoworld / gtada_youtube_entry_details.py
Created February 8, 2012 05:11
YoutubeID Entry Details
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import gdata.youtube
import gdata.youtube.service
yt_service = gdata.youtube.service.YouTubeService()
entry = yt_service.GetYouTubeVideoEntry(video_id='3KjgpNdcudU')
def PrintEntryDetails(entry):
print 'Video title: %s' % entry.media.title.text
<html>
<head>
<meta charset="UTF-8" />
<title>js sample</title>
<script type="text/javascript" src="http://a.nzk.me/static/js/jquery-1.7.1.js"></script>