ทำ Weekly Suki มา 3 สัปดาห์แบบมั่วๆ ซั่วๆ เมื่อวานพึ่งปรับเปลี่ยนให้เข้าที่เข้าทางมากขึ้น เนื่องจากไม่ได้เก็บ mp3 ไว้เอง ด้วยความขี้เกียจ และอยากเป็นตัวอย่างให้เห็นว่า ทำ podcast ไม่ต้องใช้อะไรพิเศษ แค่มี Drupal ก็เกินพอ
ทีนี้ลองมาดูว่าผมปรับอะไรไปบ้าง
Submitted by sugree on Fri, 09/05/2008 - 08:38.Yesterday, school asked my son to fill a portfolio form. The last question and my son's answer are:
When I grow up, you want to become a programmer because everyone in my home are programmers.
Probably I should change my career.
Submitted by sugree on Fri, 09/05/2008 - 08:33.It seems Python on non-linux platform, e.g., Mac and Windows, doesn't support Unicode so well. I added another option to specify target encoding if necessary and the default encoding is 'utf-8'. This patch is against Tweet to Text 2.
--encoding=utf-8 - to specify encoding match your terminal.diff --git a/track.py b/track.py index e651f51..1842e61 100644 --- a/track.py +++ b/track.py @@ -52,6 +52,9 @@ class App: parser.add_option('-p', '--pages', default=4, type='int', dest='pages', help='max pages') + parser.add_option('--encoding', + default='utf-8', dest='encoding', + help='output encoding') self.options, self.args = parser.parse_args() @@ -81,7 +84,8 @@ class App: history.reverse() for i in history: - print format_tweet(i) + tweet = format_tweet(i) + print tweet.encode(self.options.encoding, 'replace') if verbose:
I am trying to teach myself how to make a bookmarklet. This is a good chance to make a simple bookmarklet. Please try this simple bookmarklet on any Hi5 profile. Just drag below link to bookmarks toolbar. Note that you need Firefox.
The code is very simple and short.
javascript:(function(){ window.open('http://photo.lullar.com/?q='+encodeURIComponent(location.href)); })();
javascript:(function(){ location.href='http://photo.lullar.com/?q='+encodeURIComponent(location.href); })();