> base on that test i can assume that the file store in disk locally is 
> faster than the file that store in table (with or without uploadfield type 
> blob define)
> my question is should i store all file in disk locally and then use img 
> url download to static images folder? what about something like image 
> product, that can be update, i think it's not efficient when store it in 
> disk manually. what is the best way for do that?
>

You can still use an upload field for automatic uploads into the static 
folder -- just do:

import os
...

    Field('logo', 'upload', uploadfolder=os.path.join(request.folder, 
'static', 'some_subfolder'))

Then the URL would be:

URL('static', 'some_subfolder/%s' % row.logo)

Anthony

-- 
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 [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to