I went ahead and included Massimo's one-liner in the cache.py that Leonel
provided:
def fix_key_name(self,key):
#def encode_invalid(m):
#s = m.group()
#import base64
#return base64.b16encode(s)
#return self.invalid_cha
which script is this? I do not remember. There are a bunch of scripts in
web2py/scripts/setup-web2py-*.
I have to say in recent times I have used exclusively nginx which manages
memory much better.
On Monday, 25 August 2014 10:24:29 UTC-5, sasogeek wrote:
>
> I just watched the vimeo video made
If you include both file_1 and file_2 you should have two blocks (one each)
with different names within the same script. I would also suggest that you
include the part in the block. For example
{{block script1}}{{end}}
{{block script2}}{{end}}
then file1 would do
{{block script1}}
... do som
I am also getting this error after installing on Raspbian (Linux 3.12.28+ )
Issue persists on both Linux and Windows.
Any help would be much appreciated.
On Monday, August 25, 2014 5:24:29 PM UTC+2, sasogeek wrote:
>
> I just watched the vimeo video made by Massimo some time back and used it
>
thank you so much
On Wednesday, December 10, 2014 11:55:42 AM UTC-5, Massimo Di Pierro wrote:
>
> Field('password',type='password',requires=CRYPT())
>
> On Wednesday, 10 December 2014 09:57:30 UTC-6, Oliver wrote:
>>
>> where can I read or learn more about defining tables? I'm trying to
>> con
I'm wondering if it's possible to append content to a block from multiple
included files
This a resume of what I would like to do:
layout.html
{{include}}
{{block jquery_code}}
{{end}}
index.html
{{extend 'layout.html'}}
This is a paragraph
{{include 'file_
The text is wrong and the example is right.
USE THE EXAMPLE!
db = DAL('postgres://...', ...,ignore_field_case=False, entity_quoting=True)
2014-12-09 15:57 GMT+01:00 Paolo Valleri :
> try to set ignore_field_case and entity_quoting to True., see
> http://web2py.com/books/default/chapter/29/0
Hello!
I'm using jquery ui 1.11.2 in my web2py application. I put the jquery ui
folder at /static/jquery-ui-1.11.2.custom, then I import the library and
the css in the layout.html file using:
When I use the dialog widget, the dialog shows well, but the X of the
window is not shown. Is
Hi,
In my app standard email can be send using mail.send(to=['ric
The registration email is not sent however.
db.py:
## configure email
mail = auth.settings.mailer
mail.settings.server = 'logging' if request.is_local else
'mail.mampl.com:26'
mail.settings.sender = 'u...@mampl.com'
mail.
BTW, for the specific case there's IS_LIST_OF_EMAILS :P
On Wednesday, December 10, 2014 10:21:07 AM UTC+1, desta wrote:
>
> Thank you Manuele for the quick answer. Even though I read the
> documentation I didn't understand that I could do that! Thank you for
> pointing that out to me. It works g
except fiddling with translations, I don't think so.
On Wednesday, December 10, 2014 11:05:30 AM UTC+1, Manuele wrote:
>
> Hi *,
> is there a standard, or easy at least, way to change standard grid
> button text?
>
> Thank you in advance
>
> Cheers
>
> Manuele
>
--
Resources:
- http://
BTW, what you are experiencing is totally predictable, but you're "barking
at the wrong tree".
now:
migrate=True, fake_migrate=False
db.define_table('mi_tabla',
Field('f1', 'integer'),
Field('f2', 'integer'),
Field('f3', 'integer'),
Field('f4', 'integer'),
migrate='mi_t
Hi, the postgres adapter has been updated since 2.9.4, in addition at least
one patch involves json support, see here
https://github.com/web2py/web2py/commit/c4a4ee27c42e4e3b2458981888d6db6400657006
I suggest updating web2py
Paolo
On Wednesday, December 10, 2014 5:52:46 PM UTC+1, Manuele wrot
User registration and authentication -- use the auth functionality that
comes with web2py by default (see the chapter on Access Control). Create a
group called 'Instructor' and if someone is a member of that they get
additional functionality (like viewing other users' grades). Use the
built-in
There's some confusion going on, to make sure everything is correct, follow
these steps.
1. Put your models exactly has the database tables are.
2. Do a fake migrate.
3. Remove fake migrate and set migrate=True
4. Do the changes you need in your model.
--
Resources:
- http://web2py.com
- http:
Problem solved. My sample approach might help anybody with a similar
problem. It might lack some additional checks and optimizations. Please add
remarks to improve/simplify the code.
I left the model as is and added a separately populated drop-down to the
controller and an IS_IN_SET validator i
Exactely. The binary version is not supposed to work. It comes with its own
version of python therefore it does not see any module that you may have
installed. If you want to use modules like pymongo you must install Python,
install pymongo, AND run web2py source so it uses your own python versi
Field('password',type='password',requires=CRYPT())
Anyway... implementing authentication logic is very hard. It took us years
to get it right (and did we get this right?). I suggest you simply use
auth = Auth(db)
auth.define_tables()
def index(): return dict(form=auth())
and you use and extend
Field('password',type='password',requires=CRYPT())
On Wednesday, 10 December 2014 09:57:30 UTC-6, Oliver wrote:
>
> where can I read or learn more about defining tables? I'm trying to
> convert my password to more encrypted method in web2py. what is the best
> way to encrypt password in web2py?
The problem in the second code is that f1 = form().process() so f1 is a
procesed form but then you call f1.process() again. Also f1 is not returned
which means it is not displayed. If it is not displayed it is not
processed, and if not processed it is not accepted.
This should work:
def myform
Hi *,
I get this error just in the production server not in the development
one when I try to insert a record to a database table with a json
column/field.
Traceback (most recent call last):
File "/var/www/.../web2py/gluon/restricted.py", line 217, in restricted
exec ccode in environment
F
if you see the end of sql.log file. On each request try to delete the field.
[What I understand is that the definition of the table is stored in
/databases/mi_tabla.table]
timestamp: 2014-12-10T12:38:51.732946
ALTER TABLE mi_tabla DROP COLUMN f2;
timestamp: 2014-12-10T13:25:21.465148
ALTER TABLE
db.define_table('surveys',
Field('title', 'string'),
Field('description', 'string'),
Field('author', default = get_email()))
db.surveys.id.readable = False
db.surveys.title.requires = IS_NOT_EMPTY()
db.surveys.description.requires = IS_NOT_EMPTY()
Yes, just make sure to access the admin section on https.
Enrique
On Tuesday, December 9, 2014 7:30:54 PM UTC-3, Pystar wrote:
>
> my bad.
>
> On Tuesday, December 9, 2014 11:28:38 PM UTC+1, Niphlod wrote:
>>
>> checking isn't needed. if you want to access admin is either through
>> https or http
where can I read or learn more about defining tables? I'm trying to
convert my password to more encrypted method in web2py. what is the best
way to encrypt password in web2py?
I appreciate you help.
my test user table
db.define_table('users',
Field('first_name', 'text'),
Hi,
thanks for your remark. I try to avoid the simple option using
list:reference as mentioned above in favor of normalization. :)
Am Dienstag, 9. Dezember 2014 21:19:28 UTC+1 schrieb Limedrop:
>
> Hi there,
>
> The issue you have is that you are mixing a fully normalized solution and
> the web
I tried binary version. It did not work. Im trying to subscribe to
CouchDB or MongoDB online and test it instead running my db local machine.
thanks for the help.
On Friday, November 28, 2014 6:51:15 PM UTC-5, Massimo Di Pierro wrote:
>
> Are you using the source version of the binary versio
Set ignore_rw=True may be the way to go. Really thanks for your suggestion,
now I see it in the book.
--
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
Hi
I'm trying to reuse a form to de-clutter my code. The idea was to create a
form class using a SQLFORM.factory with all the validation rules set up and
then use it for each view in the module.
class form ():
'''
USAGE:
thisform = form(([clients],defaultc),([portfolios],defaultp),)
''
El miércoles, 10 de diciembre de 2014 13:11:27 UTC-3, Leonel Câmara
escribió:
>
> In this instance you don't want to fake_migrate you actually want to have
> migrate=True. Fake migrate is for when the tables defined in the models
> already reflect the tables that are really in the database and
In this instance you don't want to fake_migrate you actually want to have
migrate=True. Fake migrate is for when the tables defined in the models
already reflect the tables that are really in the database and you just
want to generate the table files.
--
Resources:
- http://web2py.com
- http:/
Hi,
For those of you who don't know Bitnami, it is ridiculously easy way to
deploy all sorts of apps on the cloud. Miles easier than Heroku in my
opinion (which is an opinion).
Bitnami works with "stacks" which are preconfigured environments and
bundled software that you download, run as a vm,
Have you defined any _after_delete functions for the table in question?
On Wednesday, December 10, 2014 4:02:58 AM UTC-5, Robin Manoli wrote:
>
> Hey,
> this happens when I try to delete a row from appadmin, or an sqlform:
>
> Traceback (most recent call last):
> File "/web2py/gluon/restricted.p
Hi all,
I've found a way to get code completion on global objects such as request,
response and db (with all your table definitions and fields!) in IDEs which
provide code completion.
I've been using this for a while now and have to say it really does speed
up my web2py development, so thought
I want to note that I will have a couple of additional fields in the
intersection table beside the relations, i.e. in the example model
components might have certain properties depending on the package:
db.define_table('component_package_association',
Field('component_id'
Hi *,
is there a standard, or easy at least, way to change standard grid
button text?
Thank you in advance
Cheers
Manuele
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/lis
That's the method I use, more or less, as it seems the simplest and most
reliable to set defaults.
Would it be easier if those fields were writable = False and readable =
False in the model, and the other form used ignore_rw=True?
You might also put
db.registrations.registered_user.default = au
Thank you Manuele for the quick answer. Even though I read the
documentation I didn't understand that I could do that! Thank you for
pointing that out to me. It works great.
Thanks again.
On Wednesday, December 10, 2014 10:51:22 AM UTC+2, Manuele wrote:
>
> Off course you can!
>
> http://web2p
Hey,
this happens when I try to delete a row from appadmin, or an sqlform:
Traceback (most recent call last):
File "/web2py/gluon/restricted.py", line 224, in restricted
exec ccode in environment
File "/web2py/applications/myapp/controllers/appadmin.py", line 671, in
File "/web2py/gluo
Off course you can!
http://web2py.com/books/default/chapter/29/07/forms-and-validators#Validators
Check out the examples reported in doc for un derstanding the standard
behaviour of validators, such as:
|>>> IS_MATCH('a')('ba')
('ba', ) # no pass
>>> IS_MATCH('a',strict=False)('ab')
('a', None)
On dreamhost I did the following after enabling passenger:
I placed all web2py files in root folder of website (not the public folder)
e.g. my.subdomain.com/
I copied handlers/wsgihandler.py to passenger_wsgi.py
I edited passenger_wsgi.py:
Added:
import sys
import os
INTERP =
Hi,
web2py features some really useful validators. Is it possible to use them
outside of forms? For example, lets assume a string that contains comma
separated emails as inputted from the user. After splitting the string to
extract individual emails, can I use the IS_EMAIL validator to validate
42 matches
Mail list logo