Hi Gurus,
I want to map multiple tags to a blog and allow users to select
predefined tags to a blog header.
I am able to see form for blogs and no errors shown after submit , but
nothing is entered to DB.
Am I missing something, please help me out.
Thanks & regards
Abhiteja
PS: My setup info
------------- I have following db definition: --------------
db.define_table('tags',
Field('name')
)
db.define_table ('blog',
Field('heading'),
Field('description' ,'text'),
Field('tags', db.tags)
)
db.blogs.tags.requires = IS_IN_DB(db, 'tags.id', 'tags.name',
multiple=True)
----------- Here is the controller definition for blogs: ----------
def blogs():
form = SQLFORM(db.blogs)
# if form.accepts(request.vars, session):
# response.flash = 'new song addded'
records = SQLTABLE(db().select(db.blogs.ALL))
return dict(form=form, records=records)