This should get you started:
http://turbogears.org/2.0/docs/main/ResponseTypes.html
Diez
Returning the actual file contents? How else should that happen?
And you should get rid of the str() - instead, use the encoding your
filesystem uses, and do something like
fname = "/path/%s/%s" % (dir_name.encode("utf-8"), file.encode("utf-8"))
Diez