Old Site‎ > ‎

Old Blogs (Posted in drupal)

admin's blog

  • Post new blog entry.

Happy Chinese New Year!

Happy Chinese new year to all!!

  • By admin at 01/30/2009 - 08:31
  •  
  • personal
  •  
  • Add new comment
  •  
  • 34 reads

Hong Kong MTR map

  • By admin at 11/23/2008 - 00:20
  •  
  • personal
  •  
  • 102 reads
  •  
  • 1 attachment

admin's blog

  • Post new blog entry.

Bugs with googleappengine under mac

The urlfetch_stub.py has bug. Replaced the original one by the attached one:

  • By admin at 05/31/2008 - 20:31
  •  
  • computer
  •  
  • Add new comment
  •  
  • 416 reads
  •  
  • 1 attachment

Python source directory for GoogleAppEngineLauncher

It is located at:

/Applications/GoogleAppEngineLauncher.app/
Contents/Resources/GoogleAppEngine-1.0.bundle/
Contents/Resources/google_appengine/

if you install GoogleAppEngineLaucher.app under /Applications

  • By admin at 05/31/2008 - 20:29
  •  
  • computer
  •  
  • Add new comment
  •  
  • 323 reads

GQL tip

Tip: Query filters do not have an explicit way to match just part of a string value, but you can fake a prefix match using inequality filters:

db.GqlQuery("SELECT * FROM MyModel WHERE prop >= :1 AND prop < :2", "abc", "abc" + "\xEF\xBF\xBD")

This matches every MyModel entity with a string property prop that begins with the characters abc. The byte string "\xEF\xBF\xBD" represents the largest possible Unicode character. When the property values are sorted in an index, the values that fall in this range are all of the values that begin with the given prefix.

  • By admin at 05/31/2008 - 17:13
  •  
  • computer
  •  
  • Add new comment
  •  
  • Read more
  •  
  • 219 reads

Using custom django template helpers with Google App Engine

From http://daily.profeth.de/2008/04/using-custom-django-template-helpers.html

This is dedicated to all you django lovers out there. If you wondered how to use custom filter functions with your Google App Engine applications, here you go:

Create a new file (I created mine in common/templatefilters.py) to hold your template helper functions.

In this file, we need to register our custom filters, so:

from google.appengine.ext import webapp
register = webapp.template.create_template_register()

After we got the registry, we now can define our custom function:

  • By admin at 05/29/2008 - 21:45
  •  
  • Add new comment
  •  
  • Read more
  •  
  • 163 reads

admin's blog

  • Post new blog entry.

OpenID authentication supported

I just added the openID support on my personal website, which means you can use any of your openIds (like the account at wordpress.org, yahoo.com) to log into my website.

If you don't know about OpenID, please read wiki article OpenID. Everybody is welcome to try on my website!

  • By admin at 05/25/2008 - 21:46
  •  
  • Add new comment
  •  
  • 119 reads

Car Sale

I am selling my car, which will be available to buyer after June 15th since I am leaving for a job in other country.

The car is 98' Honda Accord with V6 engine. We bought it in May, 2006 and it runs great! We are asking for $5800, which is significantly less than the KBB price. Please feel free to contact us if you are interested in.

Ad Title:
98 Honda Accord EX Sedan 4D

Posted:

  • By admin at 05/13/2008 - 10:22
  •  
  • 1 comment
  •  
  • Read more
  •  
  • 305 reads