Tag Archives: turbogears

Turbogears (ou zope, ou ruby) Behind Apache: Diminuindo o load.

E então, muita gente usa frameworks como o Turbogears ou alguns menos legais como o Zope ou mesmo Ruby on Rails. Para garantir um bom serviço web, segurança e disponibilidade nada melhor que deixar essas belezas rodando atrás de um proxy Apache. Com o mod_proxy do Apache2 então, as coisas ficaram ainda mais simples.
Só que [...]

Posted in Linux e Open Source, Programação | Also tagged , , | Leave a comment

Multiple AutoComplete options, ugly but works.

So, I was trying to make the Turbogears AutoComplete Widget work like the address field from gmail or hotmail. Basically to continue searching after a comma to add values. My javascript is not that good and I felt a little bad on messing with the default widgets, so I did something on the search controller [...]

Posted in Linux e Open Source, Programação | Also tagged | Leave a comment

Turbogears, Mysql and UTF. Advice Needed!

So, I have this little problem…

For design reasons, I must use SQLObject. SQLAlchemy is cool but managing all my relations ‘by hand’ is a very time consuming task and TurboGears implementation of ActiveMapper is unstable, at best.
Turboentity was a good replacement using SQLA, but the project was dropped and merged with ActiveMapper, they’re all [...]

Posted in Programação | Also tagged , | 2 Comments

Kindness of Strangers

Tá bom… Vocês ficaram com dó e não me falaram que todo trabalho que eu tive aqui foi a toa porque o TurboGears já inclui uma função que serve pra mesma coisa e faz bem mais bem feito…
:\
intel
Technorati Tags: turbogears

Posted in Linux e Open Source, Programação | Also tagged | Leave a comment

CherryPy Session e message queue

Tem vezes que eu faço umas coisas que eu acho particularmente bonitinhas. Não chega a ser Programação Arte, mas mesmo assim:
def put_message(message):
try:
cherrypy.session['message_queue'].append(message)
except KeyError:
cherrypy.session['message_queue'] = []
cherrypy.session['message_queue'].append(message)
def get_message():
try:
message = cherrypy.session['message_queue'].pop()
except (KeyError, IndexError):
return None
return message
Pra que isso? Simples assim, usando em turbogears você pode usar essa fila de mensagens para fazer redirects e não se preocupar em como [...]

Posted in Programação | Also tagged | 1 Comment