Greetings Im trying to setup a multi tenancy kind of app that will copy a web2py app to the same location with a different name(the new company's name) when that company signs up, im planning to use shutil as the folder library but im not that experienced with python
the code is the following Controller import shutil import os def join(): form = SQLFORM(db.client).process() if form.accepted: response.flash = 'Registration accepted' redirect(URL('success')) print form.client #create folder with the new company's name from the processed form #copy the content of the working app to the new folder elif form.errors: response.flash = 'Verify your Information' else: response.flash = 'please fill the form' return locals() def success(): return locals() The Model db.define_table('client', Field('name', 'string',label="Organization Name",requires=IS_NOT_EMPTY()), Field('contact_name', 'string', label='Contact Name',requires=IS_NOT_EMPTY()), Field('email', 'string', label='Email',requires=IS_NOT_EMPTY()), Field('address', 'text',label='Address',requires=IS_NOT_EMPTY()), Field('Other', 'text'), ) Regards -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.