I guess it is not wrong, but I do not recommend too much code in
controllers, controllers should be for decide the app flow.
I reccomend you to create a module in /modules
# modules/myobjects.py
from gluon import *
request = current.request
class Myobjects(object):
def showsearch(self, db):
Is there anything wrong with doing this inside default.py controller?:
def search():
def showsearch():
search =
db(db.listing.title==request.args(0)).select(db.listing.ALL)
items = []
for person in search:
items.append(DIV(A(person.first_name, _href=URL('lis
2 matches
Mail list logo