[web2py] Re: upload bug in filename

2010-06-15 Thread Swell
don't really know but i tried with that filename : aaa.pdf (which containt 111 a if you trust me :) and get the error ticket , showing this last call File "C:\Users\M\Desktop\web2py_src\we

[web2py] Re: upload bug in filename

2010-06-15 Thread Yarko Tymciurak
It looks like something else might be wrong here... how are you getting these filenames? On Jun 15, 2:37 am, Swell wrote: > don't really know but i tried with that filename : > > aaa > .p

[web2py] Re: working with views or stored procedures.

2010-06-15 Thread Sky
Thank you Jose, but I couldn't find out if you used define_table or not? can you drop me a piece of your code? i get 'invalid query' error when i query on my views. thanks . On Jun 14, 4:06 pm, Jose wrote: > I am working with a legacy database and am using many views, so as to > bridging differe

[web2py] Re: checking if table exists in database

2010-06-15 Thread mika
so what I can do if I have database already created? I would like simply to connect db and see if tables exists... by the way, metadata used by web2py to recognize tables created by itself is working only on sqlite, or on other db also? On Jun 11, 3:46 pm, mdipierro wrote: > if you set migrate=T

[web2py] crud does not support labels for forms. am i wrong ?

2010-06-15 Thread Sky
as i looked in source code of crud ( tools.py ) you can't change the 'lables' property of SQLForm returned from crud.create or crud.update methods. so I added new parameter to create and update methods of crud to be used in constructing SQLForm. def update( self, table,

[web2py] Re: Unable to connect to mysql DB - sql.py mod

2010-06-15 Thread The Czar
When I tried to enter a bacl slashed field (Odyssey\'s), it failed. So I guess the default behavior is effectively NO_BACKSLASH_ESCAPES On Jun 14, 11:23 pm, mdipierro wrote: > what is the default bahvior? > > On Jun 14, 9:51 am, The Czar wrote: > > > I just checked the docs for the older version

[web2py] Re: working with views or stored procedures.

2010-06-15 Thread Jose
On 15 jun, 05:12, Sky wrote: > Thank you Jose, > but I couldn't find out if you used define_table or not? > can you drop me a piece of your code? > i get 'invalid query' error when i query on my views. > They are declared in the same way that a real table. Then you can create queries, use them

[web2py] Re: Internal error

2010-06-15 Thread Cory Coager
Any idea why sqlite is not working?

Re: [web2py] Re: my app instead of welcome app???

2010-06-15 Thread Jean-Guy
On 2010-06-15 02:45, mdipierro wrote: se you do not have too, you can use ruotes already for this purpose. I read somewhere that we should modify the route in apache conf... I know I am not very precise I will try to found back the post of doc files... What the best practice? Jonhy

Re: [web2py] Re: my app instead of welcome app???

2010-06-15 Thread Jean-Guy
On 2010-06-15 02:45, mdipierro wrote: se you do not have too, you can use ruotes already for this purpose. Here : http://www.web2py.com/AlterEgo/default/show/42

[web2py] where are the auth table model?

2010-06-15 Thread Jean-Guy
Hello, I would like to get the auth tables models to implement them in my app cause web2py complain that they already are define when I move change from dev to prod database within the same app... I had found those models, can't remember where they were... ;-) Jonhy

[web2py] Re: where are the auth table model?

2010-06-15 Thread Pai
there's an option to customized it. see below http://web2py.com/book/default/section/8/1?search=Customizing+Auth hope this helps :) Pai On Jun 15, 10:17 am, Jean-Guy wrote: > Hello, > > I would like to get the auth tables models to implement them in my app > cause web2py complain that they al

Re: [web2py] Re: where are the auth table model?

2010-06-15 Thread Jean-Guy
On 2010-06-15 11:36, Pai wrote: there's an option to customized it. see below http://web2py.com/book/default/section/8/1?search=Customizing+Auth hope this helps :) Pai On Jun 15, 10:17 am, Jean-Guy wrote: Hello, I would like to get the auth tables models to implement them in my app ca

Re: [web2py] Re: my app instead of welcome app???

2010-06-15 Thread Thadeus Burgess
bah, whats the use. -- Thadeus On Tue, Jun 15, 2010 at 10:14 AM, Jean-Guy wrote: > On 2010-06-15 02:45, mdipierro wrote: > > se you do not have too, you can use ruotes already for this > purpose. > > > Here : http://www.web2py.com/AlterEgo/default/show/42

[web2py] Trouble doing manual insert of upload file

2010-06-15 Thread weheh
# model db.define_table('srcfile', Field('name','upload',length=50,label=T('Upload file'),autodelete=True, uploadseparate=True, requires=( IS_UPLOAD_FILENAME(extension='pdf|txt|doc|htm|html|xml|ppt'), IS_LENGTH(500,10)) ), ) # controller ... file_form=SQLFORM.factor

Re: [web2py] Re: my app instead of welcome app???

2010-06-15 Thread Jonathan Lundell
On Jun 14, 2010, at 8:40 PM, Richard wrote: > would that go against the web2py philosophy of having no configuration > files? Not really. It could go in routes.py, which already (potentially) exists. > > > On Jun 15, 1:33 pm, Thadeus Burgess wrote: >> Why can't we configure the default name o

[web2py] Re: checking if table exists in database

2010-06-15 Thread Yarko Tymciurak
The first question you might answer is: how would you do this without web2py? What are your steps? Then, you can ask - how does web2py get into this, and what web2py facilities (if any) do something like this? A few observations: If you 'create' a web2py table definition for an existing table,

Re: [web2py] Re: my app instead of welcome app???

2010-06-15 Thread Jean-Guy
On 2010-06-15 11:47, Thadeus Burgess wrote: bah, whats the use. -- Thadeus On Tue, Jun 15, 2010 at 10:14 AM, Jean-Guy wrote: On 2010-06-15 02:45, mdipierro wrote: se you do not have too, you can use ruotes already for this purpose. Here : http://www.web2py.com/AlterEgo/default/show

[web2py] Re: where are the auth table model?

2010-06-15 Thread annet
Hi Johny, I am facing the same problem, since there seems to be no proper solution I use the following workaround: I move everything that has to do with auth to its own db_01 file and define all my tables in a separate db_00.py file. Now every time a table definition changes, and I save db_00.py

Re: [web2py] Re: my app instead of welcome app???

2010-06-15 Thread Thadeus Burgess
I ment... whats the use attempting to convince Massimo that this is a good idea although many community members want it. He has been against this suggestion for the last year that I have been using web2py and this has been brought up many times, and he probably won't ever change his mind, so we sho

[web2py] Date picker widget

2010-06-15 Thread greenpoise
How is it called? I have a custom form (no SQLForm) how would I get the date picker to come out?? D.

Re: [web2py] Re: my app instead of welcome app???

2010-06-15 Thread Jean-Guy
On 2010-06-15 13:16, Thadeus Burgess wrote: I ment... whats the use attempting to convince Massimo that this is a good idea although many community members want it. He has been against this suggestion for the last year that I have been using web2py and this has been brought up many times, and he

[web2py] Re: Defining db.py for the first time problem (db references possible?)

2010-06-15 Thread zsouthboy
Hi Yarko, Thanks for the help! I had initially tried doing what the introductory docs show (which is marking a reference like ("image", db.image) for a column), which fails because there is no member 'image' of db yet. Then I consulted the technical docs and saw that instead "reference image" shou

[web2py] Re: rocket.ssl not found

2010-06-15 Thread The Czar
Take a look @ this thread...http://groups.google.com/group/web2py/ browse_thread/thread/704f055f74bfc8ed On Jun 14, 1:25 pm, davidjensen wrote: > I am running 1.79.2 on red hat enterprise linux with python 2.5 on a > hosting service with static ip and using port 8080. I have openssl. > > I am get

[web2py] Does DAL supports creating DBs?

2010-06-15 Thread Phyo Arkar
Hello all I am just wondering if DAL supports creating DBs before loading in models? I am Thinking about developing a DB Admin for web2py , which will going to work like phpMyadmin. But i am not sure how DAL of Web2py can create DBs. I think we have to use python-mysql to do the work? db=MySQLd

Re: [web2py] Does DAL supports creating DBs?

2010-06-15 Thread Jean-Guy
On 2010-06-15 15:03, Phyo Arkar wrote: ot sure how DAL of Web2py can create DBs. I think we have to use python-mysql to do the work? When you define a model web2py create the database for you!! You have to tell wich RDBMS you use... db=DAL ('

[web2py] Re: where are the auth table model?

2010-06-15 Thread weheh
Annet: just to be sure you understand ... to do a custom auth you need: from gluon.tools import * auth=Auth(globals(),db) auth_table=db.define_table( auth.settings.table_user_name, # required fields Field('email',length=128,label=T('Email'),default='',unique=True), Field('password','passw

[web2py] Writing good documentation

2010-06-15 Thread b00m_chef
http://jacobian.org/writing/great-documentation/

[web2py] Re: Does DAL supports creating DBs?

2010-06-15 Thread Phyo Arkar
i meant Databases, i know it creates Tables. db=DAL('mysql://username:passw...@localhost/test' ) #means you have a database named test In my case , Database is non-existance , well a user input name of database to create , lets say testdb and it creates. On Jun 15, 7:55 pm, Jean-Guy wrote:

[web2py] How to change the /default

2010-06-15 Thread Jean-Guy
Hello, I would remove completly default folder in my app... I changed many files to not use default folder anymore, but logout function and initialization of the app still require to reach default/index.html I change my routes.py that way as Massimo wrote : routes_in = (('/', '/app/newfolder

Re: [web2py] Re: Does DAL supports creating DBs?

2010-06-15 Thread Jean-Guy
On 2010-06-15 17:01, Phyo Arkar wrote: i meant Databases, i know it creates Tables. db=DAL('mysql://username:passw...@localhost/test' ) #means you have a database named test In my case , Database is non-existance , well a user input name of database to create , lets say testdb and it creates

Re: [web2py] Re: Documentation on moving common code into modules?

2010-06-15 Thread David Mitchell
Thanks everyone, Didn't work for me for a while, then I rewired my brain from "Ruby-mode" to "Python-mode" and was off and running! Dave M. On 15 June 2010 10:48, weheh wrote: > +1 regarding Yarko's suggestion. Putting common code into modules is > probably the easiest way to have it visible t

Re: [web2py] Re: sqlite modeller

2010-06-15 Thread Doug Warren
The problem I found with the web2py exporting though is that it dumps it based on how you drew it on the page, top left first working to the right then the next row etc... So if you happened to placed a foreign key on a lower section of the paper than where you're using it, you'll get an import er

[web2py] Looking for web2py AJAX "recipes"

2010-06-15 Thread David Mitchell
Hello all, I've got a bunch of AJAX pages to create, with tasks like: - pick a selection from a drop-down list - based on that selection, populate another drop-down list - start typing in a text field - with each character typed, do a search in a DB table for fields matching the string typed and

[web2py] Re: Does DAL supports creating DBs?

2010-06-15 Thread Phyo Arkar
What i am doing is a Webbased DBA like phpMyAdmin. That can be done by executing cursor import MySQLdb db=MySQLdb.connect(user='root') db.cursor().execute('CREATE DATABASE casedb') It would be easy to implement in DAL too. On Jun 15, 9:20 pm, Jean-Guy wrote: > On 2010-06-15 17:01, Phyo Arka

[web2py] Re: Does DAL supports creating DBs?

2010-06-15 Thread Phyo Arkar
This works. db=MySQLdb.connect(user='root') cur =db.cursor() cur.execute('CREATE DATABASE testdb') On Jun 15, 9:20 pm, Jean-Guy wrote: > On 2010-06-15 17:01, Phyo Arkar wrote: > > >   i meant Databases, i know it creates Tables. > > > db=DAL('mysql://username:passw...@localhost/test' )  #means yo

[web2py] Re: working with views or stored procedures.

2010-06-15 Thread Yarko Tymciurak
On Jun 15, 7:13 am, Jose wrote: > On 15 jun, 05:12, Sky wrote: > > > Thank you Jose, > > but I couldn't find out if you used define_table or not? > > can you drop me a piece of your code? > > i get 'invalid query' error when i query on my views. > > They are declared in the same way that a real

[web2py] Re: my app instead of welcome app???

2010-06-15 Thread Yarko Tymciurak
On Jun 15, 1:05 pm, Jean-Guy wrote: > On 2010-06-15 13:16, Thadeus Burgess wrote: > > > > > I ment... whats the use attempting to convince Massimo that this is a > > good idea although many community members want it. He has been against > > this suggestion for the last year that I have been using

[web2py] Re: where are the auth table model?

2010-06-15 Thread Yarko Tymciurak
On Jun 15, 10:39 am, Jean-Guy wrote: > On 2010-06-15 11:36, Pai wrote: > > > > > there's an option to customized it.  see below > > >http://web2py.com/book/default/section/8/1?search=Customizing+Auth > > > hope this helps :) > > > Pai > > > On Jun 15, 10:17 am, Jean-Guy  wrote: > > >> Hello, > > >

[web2py] Any Server side File management appliance in python?

2010-06-15 Thread Phyo Arkar
Hi All Is there any appliance with Server Side file brower , or any other python webapp have it? I am bored to do my own and going to use if there anything out there. Like Net2ftp . Already existed in Appliances? Or somewhere else? Regards Phyo.

[web2py] Unpredictable sqlite3.dll version being loaded by web2py.exe

2010-06-15 Thread Salvor Hardin
It would be great if web2py.exe loads sqlite3.dll from the same directory as web2py.exe. Unfortunately, web2py loads C:\Windows\System32\sqlite3.dll which is the most unpredictable version of sqlite3.dll on Windows. I didn't realize this until I tried replacing C:\web2py\sqlite3.dll with an encry

[web2py] Re: WordPressClone/PyPress GAE fix

2010-06-15 Thread Richard
awesome! I am looking for a simple web2py blog system to run on GAE. in your message "for" got connected with the url: http://www.molhokwai.net/blog On Jun 15, 7:12 pm, molhokwai wrote: > Hello there... > > Implemented fixes to run PyPress on GAE > (Seehttp://www.molhokwai.net/blogforhow it's

[web2py] Re: WordPressClone/PyPress GAE fix

2010-06-15 Thread Richard
do you have a public repository for your updates? Also there seems to already be a version of pypress on GAE since 09: http://pp4gae.appspot.com/ On Jun 16, 10:14 am, Richard wrote: > awesome! I am looking for a simple web2py blog system to run on GAE. > > in your message "for" got connected wi

[web2py] code broke, help

2010-06-15 Thread greenpoise
Ok this used to work: def qryfecha(): form=FORM (H1(TABLE (TR(('From:',INPUT(_name="desde",_class='date',_id="desde",requires=IS_DATE())), ('To:',INPUT(_name="to",_class='date',_id="to",default=request.now,requires=IS_DATE(), INPUT(_type='submit'))) fromvar=request.vars.desde t

[web2py] Re: code broke, help

2010-06-15 Thread mr.freeze
Do you get an error? If so, can you show the traceback? On Jun 15, 8:01 pm, greenpoise wrote: > Ok this used to work: > > def qryfecha(): > >     form=FORM (H1(TABLE > (TR(('From:',INPUT(_name="desde",_class='date',_id="desde",requires=IS_DATE > ())), > > ('To:',INPUT(_name="to",_class='date',_i

[web2py] Re: code broke, help

2010-06-15 Thread greenpoise
here it is: Error traceback 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. Traceback (most recent call last): File "/home/danel/Applications/web2py/gluon/restricted.py", line 178, in restricted exec ccode in environment File "/home/danel/Applications/web2py/applications/shroomV

[web2py] Re: sqlite modeller

2010-06-15 Thread Yarko Tymciurak
...in the years we've been looking at this tool on these forums (and it is a cool tool), it just never really seemed justified in practice. It always seems easiest to code up your tables. It does make for nice documentation images, though YMMV On Jun 15, 4:46 pm, Doug Warren wrote: > The

[web2py] Re: code broke, help

2010-06-15 Thread mr.freeze
I would just check that fromvar and tovar are not None before getting the rows. On Jun 15, 8:40 pm, greenpoise wrote: > here it is: > > Error traceback > > 1. > 2. > 3. > 4. > 5. > 6. > 7. > 8. > 9. > 10. > 11. > 12. > 13. > 14. > 15. > 16. > > Traceback (most recent call last): >   File "/home/d

[web2py] Re: Unpredictable sqlite3.dll version being loaded by web2py.exe

2010-06-15 Thread Yarko Tymciurak
On Jun 15, 6:29 pm, Salvor Hardin wrote: > It would be great if web2py.exe loads sqlite3.dll from the same > directory as web2py.exe. > > Unfortunately, web2py loads C:\Windows\System32\sqlite3.dll which is > the most unpredictable version of sqlite3.dll on Windows. Hmmm this may have to d

[web2py] Re: Looking for web2py AJAX "recipes"

2010-06-15 Thread GoldenTiger
http://www.web2pyslices.com is usefull for me On 15 jun, 23:48, David Mitchell wrote: > Hello all, > > I've got a bunch of AJAX pages to create, with tasks like: > - pick a selection from a drop-down list > - based on that selection, populate another drop-down list > > - start typing in a text fi

[web2py] Re: Any Server side File management appliance in python?

2010-06-15 Thread GoldenTiger
http://elrte.ru/en/elfinder I have found this usefull file manager, a python webapp, you will like it On 16 jun, 01:06, Phyo Arkar wrote: > Hi All > > Is there any appliance with Server Side file brower , or any other > python webapp have it?  I am bored to do my own and going to use if > there

[web2py] Re: Defining db.py for the first time problem (db references possible?)

2010-06-15 Thread Yarko Tymciurak
On Jun 15, 1:56 pm, zsouthboy wrote: > Hi Yarko, > > Thanks for the help! > I had initially tried doing what the introductory docs show (which is > marking a reference like ("image", db.image) for a column), which > fails because there is no member 'image' of db yet. > Then I consulted the techni

Re: [web2py] Re: Documentation on moving common code into modules?

2010-06-15 Thread Thadeus Burgess
web2py does NOT follow normal python conventions. You are writing web2py code not python code =) -- Thadeus On Tue, Jun 15, 2010 at 4:41 PM, David Mitchell wrote: > Thanks everyone, > Didn't work for me for a while, then I rewired my brain from "Ruby-mode" to > "Python-mode" and was off and

[web2py] Re: Unpredictable sqlite3.dll version being loaded by web2py.exe

2010-06-15 Thread Salvor Hardin
On Jun 15, 9:12 pm, Yarko Tymciurak wrote: > On Jun 15, 6:29 pm, Salvor Hardin wrote: > > > It would be great if web2py.exe loads sqlite3.dll from the same > > directory as web2py.exe. > > > Unfortunately, web2py loads C:\Windows\System32\sqlite3.dll which is > > the most unpredictable version

[web2py] Re: Unpredictable sqlite3.dll version being loaded by web2py.exe

2010-06-15 Thread Yarko Tymciurak
On Jun 15, 10:26 pm, Salvor Hardin wrote: > On Jun 15, 9:12 pm, Yarko Tymciurak > wrote: > > > > > > > On Jun 15, 6:29 pm, Salvor Hardin wrote: > > > > It would be great if web2py.exe loads sqlite3.dll from the same > > > directory as web2py.exe. > > > > Unfortunately, web2py loads C:\Windows\S

[web2py] Re: crud does not support labels for forms. am i wrong ?

2010-06-15 Thread mdipierro
No because this should be done with db.table.field.label='new label' On Jun 15, 3:57 am, Sky wrote: > as i looked in source code of crud ( tools.py ) you can't change the > 'lables' property of SQLForm returned from crud.create or crud.update > methods. > so I added new parameter to create and u

[web2py] Re: Unable to connect to mysql DB - sql.py mod

2010-06-15 Thread mdipierro
I think it is the opposite. You are vulnerable to injections. On Jun 15, 5:35 am, The Czar wrote: > When I tried to enter a bacl slashed field (Odyssey\'s), it failed. So > I guess the default behavior is effectively NO_BACKSLASH_ESCAPES > > On Jun 14, 11:23 pm, mdipierro wrote: > > > what is th

[web2py] Re: Internal error

2010-06-15 Thread mdipierro
No. the error you reported was with postgresql 8.1. What is the problem with sqlite? On Jun 15, 7:57 am, Cory Coager wrote: > Any idea why sqlite is not working?

[web2py] Re: Trouble doing manual insert of upload file

2010-06-15 Thread mdipierro
May be a bug. can you try? file_form.accepts(request.vars,formname='file_form',onvalidation=check_file_in): request.vars.name.file.seek(0) ### add this line db.srcfile.insert( name=db.srcfile.name.store( request.vars.name.file,request.vars.name.filename), ) On

[web2py] Re: Trouble doing manual insert of upload file

2010-06-15 Thread mdipierro
Actually this would work but it is not the best way, ... the problem is that the storage is already performed by accepts so you must do simply file_form.accepts(request.vars,formname='file_form',onvalidation=check_file_in): db.srcfile.insert(name=form.vars.name) On Jun 15, 10:44 pm, mdipi

[web2py] Re: rocket.ssl not found

2010-06-15 Thread mdipierro
There should be a more graceful report about this error... Tim? On Jun 15, 1:57 pm, The Czar wrote: > Take a look @ this thread...http://groups.google.com/group/web2py/ > browse_thread/thread/704f055f74bfc8ed > > On Jun 14, 1:25 pm, davidjensen wrote: > > > I am running 1.79.2 on red hat enterpr

[web2py] Re: Unpredictable sqlite3.dll version being loaded by web2py.exe

2010-06-15 Thread Salvor Hardin
On Jun 15, 10:31 pm, Yarko Tymciurak wrote: > On Jun 15, 10:26 pm, Salvor Hardin wrote: > > > I got an unexpected result. > > > C:\Python25\python.exe loads C:\Python25\Dlls\sqlite3.dll when I issue > > "import sqlite3" > > > And, C:\web2py\web2py.exe loads C:\Windows\system32\sqlite3.dll > > imm

[web2py] Re: code broke, help

2010-06-15 Thread mdipierro
This should never have worked. On Jun 15, 8:57 pm, "mr.freeze" wrote: > I would just check that fromvar and tovar are not None before getting > the rows. > > On Jun 15, 8:40 pm, greenpoise wrote: > > > here it is: > > > Error traceback > > > 1. > > 2. > > 3. > > 4. > > 5. > > 6. > > 7. > > 8. >

[web2py] Re: Looking for web2py AJAX "recipes"

2010-06-15 Thread mdipierro
Not sure if that helps you but there is an ajax chapter in http:/ web2py.com/book On Jun 15, 4:48 pm, David Mitchell wrote: > Hello all, > > I've got a bunch of AJAX pages to create, with tasks like: > - pick a selection from a drop-down list > - based on that selection, populate another drop-dow

[web2py] Re: Defining db.py for the first time problem (db references possible?)

2010-06-15 Thread mdipierro
Because I think if you have a table1 that reference a table2 and a table2 that reference table1 something is wrong. I am not even sure all the database backends support that. think about it, you cannot insert a record in table1 without the record in table2 to reference and vice versa. The proper wa

[web2py] Re: Unpredictable sqlite3.dll version being loaded by web2py.exe

2010-06-15 Thread mdipierro
I guess this may be an issue in the order in sys.path. Will look into this next week as I return from this conference. On Jun 15, 6:29 pm, Salvor Hardin wrote: > It would be great if web2py.exe loads sqlite3.dll from the same > directory as web2py.exe. > > Unfortunately, web2py loads C:\Windows\S

[web2py] Re: Trouble doing manual insert of upload file

2010-06-15 Thread weheh
Nice and simple. Thanks Massimo. But FWIW, this doesn't rename the no_table.name.blahblah.txt file to srcfile_table.name.blahblah.txt, which may or may not be the right thing to do -- I'm not sure. Since I am uploading everything through the factory form, all fields are no_table fields. Since I ev

[web2py] Re: Trouble doing manual insert of upload file

2010-06-15 Thread weheh
Yes -- this works, too, but perhaps it's a little "ugly". I prefer the other method (but see previous post). On Jun 15, 11:44 pm, mdipierro wrote: > May be a bug. can you try? > > file_form.accepts(request.vars,formname='file_form',onvalidation=check_file_in): >      request.vars.name.file.seek(0

[web2py] Re: Trouble doing manual insert of upload file

2010-06-15 Thread mdipierro
aha, you can do this file_form=SQLFORM.factory(,table_name='srcfile') file_form.accepts(request.vars,formname='file_form',onvalidation=check_file_in): db.srcfile.insert(name=form.vars.name) On Jun 16, 12:34 am, weheh wrote: > Nice and simple. Thanks Massimo. > > But FWIW, this doesn't

[web2py] Re: Trouble doing manual insert of upload file

2010-06-15 Thread weheh
I don't think this will work since my factory is using multiple tables. I don't mean to digress, but another question is, how to open the file during the onvalidation? I need to open the file and read it in to check the contents for stuff that will determine whether it's valid or not. I've tried:

[web2py] Re: where are the auth table model?

2010-06-15 Thread annet
Hi Richard, > I don't know whether the problems you're having might stem from not > following this structure. I am pretty sure I got the structure right, Massimo helped me sort that out. auth.settings.table_user = db.define_table('auth_user', Field('first_name',length=24,default=''), Fie

[web2py] Re: Trouble doing manual insert of upload file

2010-06-15 Thread mdipierro
Try this: file_form=SQLFORM.factory(db.auth_user,db.othertable,db.srcfile) ... if FORM.accepts(file_form,request.vars,formname='file_form'): # no upload check_file_in(file_form) # same as onvalidation if not file_form.errors: db.srcfile.insert( name=db.srcfile.name.s