Hello,
for certain purposes I very much like convenience of static site
generators (e.g. Python-powered Nikola) which allows using makrdown/reST
markup to write offline and then simply update the site.
However, there is time when one would like some dynamic capabilities as
well, so I wonder if
Il 14/12/13 01:29, 黄祥 ha scritto:
hi,
is it possible for dal store data in more than 1 database?
heve you read this part of the documentation?
http://web2py.com/books/default/chapter/29/06/the-database-abstraction-layer#Replicated-databases
M.
let say i use database 'production1' with mysql
I am impressed at how helpful you have been on this Jonathon.
It does say in the mht file that it is windows-1252 encoded.
It turns out that
s.decode('cp1252').encode('utf-8')
is working correctly. I mistakenly thought it was not
because I got this error
UnicodeEncodeError: 'charmap'
Hi Rene / Ruud
I have been intending to look at this, but decided it would be easier to
wait for the plugin, if one was being made. Is it still intended to make
a plugin?
Best wishes, D
On Wednesday, 20 November 2013 03:17:55 UTC, Rene Dohmen wrote:
Hi List,
Ruud, thanks for
Hi Anthony, I added CORS stuff to my Apache httpd.conf as per this
http://enable-cors.org/server_apache.html but I'm still getting the same
error message. Any ideas about how to push through this?
On Sunday, December 15, 2013 1:13:55 AM UTC+8, Anthony wrote:
Is it in fact a cross-origin
Hi,
I wish I could help, but I don't know what is it about.
Good luck.
Ashraf
--
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
Thanks, I got what I wanted this morning. Adding it here to improve my
question as well.
I originally used this from the literature:
Field('modified_by', 'reference auth_user',
default=auth.user_id, update=auth.user_id, writable=False),
This is what I needed:
On Friday, December 13, 2013 1:23:49 PM UTC-5, TSmith wrote:
There exists a table. I added the modified_by field as shown below. I
also tried the second version which is what I really want.
db.define_table('DOCUMENTATION',
Field('documentation_type','string'),
I don't know. Does it happen in all browsers?
On Monday, December 16, 2013 8:38:17 AM UTC-5, weheh wrote:
Hi Anthony, I added CORS stuff to my Apache httpd.conf as per this
http://enable-cors.org/server_apache.html but I'm still getting the same
error message. Any ideas about how to push
Yah, I see it on other browsers: Redirects are not allowed for CORS
preflight requests. and then XMLHttpRequest: Network Error 0x8007005,
Access is denied.
On Monday, December 16, 2013 10:16:40 PM UTC+8, Anthony wrote:
I don't know. Does it happen in all browsers?
On Monday, December 16,
@weheh can you try a custom jQuery.ajax cross domain call for
testing/debugging? (just load something from HTTP to HTTPS)
On Mon, Dec 16, 2013 at 2:38 PM, weheh richard_gor...@verizon.net wrote:
Hi Anthony, I added CORS stuff to my Apache httpd.conf as per this
@Marin: Thanks for your suggestion. I believe that that is precisely what
is causing this issue. The original call is an HTTP call. It's followed by
an HTTPS that results in the error message. But still no idea how to get
the https call to go through.
On Monday, December 16, 2013 10:45:45 PM
On 16 Dec 2013, at 2:18 AM, peter peterchutchin...@gmail.com wrote:
I am impressed at how helpful you have been on this Jonathon.
It does say in the mht file that it is windows-1252 encoded.
It turns out that
s.decode('cp1252').encode('utf-8')
is working correctly. I mistakenly
Well, as I said, try your own jquery.ajax call.
If it works, then CORS is enabled but component load is failing.
If it doesn't work, then you didn't enable CORS correctly.
You should also try $.ajax({crossDomain: true, ...});
JQuery should add it automatically but maybe it's not detecting it
hi,
we can list all apps that web2py implies, for sure python, if we check the
presence of web2py.js I would also set jquery, what else (see all apps here
https://github.com/ElbertF/Wappalyzer/blob/master/share/apps.json)?
We could also check for the presence of either X-Powered-By:web2py in the
Same problem for me using Chrome and Midori on Linux after upgrading to
2.8.2 However I try to launch the editor I get a blank screen. In the java
console I get a load of this type of error:
GET http://127.0.0.1:8000/admin/static/-2.7.3/codemirror/lib/codemirror.css
404 (NOT FOUND)
So
Hm. It should be looking for
/admin/static/_2.7.3/codemirror/lib/codemirror.css,
so _2.7.3 and not -2.7.3.
I don't think this dash is a direct typo in the web2py code. A rewrite rule
somewhere, regex gone wrong?
BTW, the number there is only indirectly related to the web2py version, it
On Monday, 16 December 2013 17:06:28 UTC, LightDot wrote:
Hm. It should be looking for
/admin/static/_2.7.3/codemirror/lib/codemirror.css,
so _2.7.3 and not -2.7.3.
I don't think this dash is a direct typo in the web2py code. A rewrite rule
somewhere, regex gone wrong?
I have
I have some reference fields in a table and I want to be able to allow them
to be null (for a while. I have sent notnull and required to False in the
model but I get an error when I go to create a record in appadmin. Clearly
I can set them to point to a dummy record in my application but I am
Is it possible to configure web2py so that when you open the binary it
automatically launches web2py on pre-configured port (click the binary and
the web page comes updon't need to start the server)? Also, I noticed
the new build has the web2py branding on the start server dialog box. Is
Guys,
i changed the way of implementing the composite key, now i'm concatenating
both fields into 1.
*db.define_table('t_user_has_companies',*
*Field('unikey', notnull=True,required=True, compute=lambda
r: str(r.USER_ID) + str(r.COMP_ID)),*
*
After further investigation I've found what triggers this problem for me.
If you have several virtualhosts in apache, on the same IP:PORT, each
running from their own web2py folder, you can get this problem.
For instance, you only have 2 subdomains
foo.example.com
bar.example.com
for
Why do you want to do this?
Reference fields include the IS_IN_DB validator by default.
I guess you could make it a plain integer field and use
requires=IS_EMPTY_OR(IS_IN_DB(db, ...))
On Monday, December 16, 2013 12:28:14 PM UTC-5, Phil Hughes wrote:
I have some reference fields in a table
The record will become a relationship between two people but the way it
works the first person creates the record and gets an ID (not the id field
in the record but and identify number for building the relationship.) That
ID is then sent to the other party (effectively by internal email) so
If there's already a link between the user and the company, you want the
company to NOT appear in the drop down, right?
In order for this to work you have to have the user id. Ordinarily it would
be the last item on request.args
So, simplifying because I don't enjoy typing all that much, the
It is here https://github.com/ElbertF/Wappalyzer/pull/397
Paolo
2013/12/16 Paolo Valleri paolo.vall...@gmail.com
hi,
we can list all apps that web2py implies, for sure python, if we check the
presence of web2py.js I would also set jquery, what else (see all apps here
I guess you could make it a plain integer field and use
requires=IS_EMPTY_OR(IS_IN_DB(db, ...))
I think that's the way to go, but you don't have to make it a plain integer
field -- can still be a reference field.
Anthony
--
Resources:
- http://web2py.com
- http://web2py.com/book
Issue resolved. The source of all trouble was that the Scheduler uses the
same db connection as the task it executes. Thus output updates (print
'!clear!%(progress)s' % progress) changes the connection status, randomly,
hence the strange exceptions.
Suggestion: explicitly mention this as a
How about generating most of the pages and serving them as static content
(e.g. templates that have nothing to render, just plain HTML); then having
some templates that really have stuff that needs to be rendered and
processed (e.g. a contact form + a POST handler) ?
--
Resources:
-
Perfect. Clearly the trick here is just getting used to all the options
available. I have yet to find something I can't do but, much like learning
any new language (computer or natural) you just need to get used to it.
Thanks.
On Monday, December 16, 2013 3:17:58 PM UTC-6, Anthony wrote:
I
OK, to answer Paolo's question on Friday as to what had changed to make it
not work at all - nothing, only the passage of time. So as an experiment I
rebooted my RPi once again and behold it all sprang into life. I have
rebooted several times since the Web2py upgrade and each time it works to
Hopefuly it can be useful to someone else.
Perhaps you want to post this also in web2pyslices.com, which has a
packages database. Also consider making a plugin of the feature for more
portability between apps (the admin app now supports automatic download and
installation of plugins).
--
Hi, Massimo,
Is it possible for a better documentation for Openshift support? The link
above is dead on web2py. Andrew Replogle made a cartridge, but it's not
maintained anymore. I tried to manually update web2py by various stupid
ways, no luck.
I commented on his github page:
On Saturday, December 14, 2013 10:24:56 AM UTC-8, John Zumsteg wrote:
I found the problem in a totally unexpected place. I am running the apps
on Chrome, and had Firebug Lite installed. For the heck of it, I disabled
Firebug, and all came back.
Interesting. Thanks for the post-back.
/dps
a, i c, thank you so much for the reference link, is this work?
db =
DAL(['sqlite://storage.db','mysql://username:password@localhost/test','postgres://username:password@localhost/test'])
best regards,
stifan
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
-
I'm getting an error on this (*the error is type 'exceptions.TypeError'
process() takes exactly 1 argument (2 given) **on if
form.process(dupe_check).accepted:*).
here is what my files looks like
*db.py:*
*db.define_table('user_company',*
* Field('user_id', 'reference auth_user'),*
*
You can:
gird(,user_signature=False)
But be careful to use a decorator to manage permissions for the action that
contains the grid.
On Sunday, 15 December 2013 19:48:46 UTC-6, Scott Hunter wrote:
Is there a way to have a link go to a controller function that uses a
smart grid, but
You can make your own .BAT file.
On Sunday, 15 December 2013 19:32:57 UTC-6, Brando wrote:
Is it possible to configure web2py so that when you open the binary it
automatically launches web2py on pre-configured port (click the binary and
the web page comes updon't need to start the
:-)
On Monday, 16 December 2013 14:59:24 UTC-6, Paolo Valleri wrote:
It is here https://github.com/ElbertF/Wappalyzer/pull/397
Paolo
2013/12/16 Paolo Valleri paolo@gmail.com javascript:
hi,
we can list all apps that web2py implies, for sure python, if we check
the presence of
Is this the problem for everybody else in the thread?
On Monday, 16 December 2013 12:44:54 UTC-6, Leonel Câmara wrote:
After further investigation I've found what triggers this problem for me.
If you have several virtualhosts in apache, on the same IP:PORT, each
running from their own
Nice! I added it to the appliances repository.
On Monday, 16 December 2013 12:21:01 UTC-6, Leonel Câmara wrote:
I did this to see how I could integrate dropzone.js (
http://www.dropzonejs.com/ ) with web2py as I'm thinking of using it in
some of my projects.
Hopefuly it can be useful to
I agree. We'll look into it.
On Monday, 16 December 2013 17:09:19 UTC-6, Yi Liu wrote:
Hi, Massimo,
Is it possible for a better documentation for Openshift support? The link
above is dead on web2py. Andrew Replogle made a cartridge, but it's not
maintained anymore. I tried to manually
form.process(dupe_check).accepted:
*should be*
orm.process(onvalidation=dupe_check).accepted:
On Monday, 16 December 2013 20:04:02 UTC-6, Michel Hayek wrote:
I'm getting an error on this (*the error is type
'exceptions.TypeError' process() takes exactly 1 argument (2 given) **on
if
Hello,
Our product has features which can be enabled or disabled depending on what
the user has purchased. I would like to use the built-in Auth permissions
functionality to achieve this effect. However, I'm not sure of what's the
best way to proceed with its implementation. The two scenarios
My bad. :(
Too much typing today.
On Monday, December 16, 2013 10:34:08 PM UTC-5, Massimo Di Pierro wrote:
form.process(dupe_check).accepted:
*should be*
orm.process(onvalidation=dupe_check).accepted:
On Monday, 16 December 2013 20:04:02 UTC-6, Michel Hayek wrote:
I'm getting an error
You can make a group buyers and they buy something
auth.add_membership(role=buyers) then check permissions with
@auth.requires_membership(buyers)
or explicitly
if auth.has_membership(role=buyers): ...
On Monday, 16 December 2013 21:38:08 UTC-6, Henry Nguyen wrote:
Hello,
Our product has
I got another error now
type 'exceptions.ValueError' invalid literal for long() with base 10:
'user_company'
*def dupe_check(form):if db((db.company_user.user_id==request.args(-1))
(db.company_user.company_id==form.vars.company_id)).count():
form.errors['company_id'] = 'Company
Thanks, Massimo!
As a relief for now, I have edited the wiki page on how to upgrade to the
latest web2py, with hint from Andrew:
https://github.com/prelegalwonder/openshift_web2py/wiki
On Monday, December 16, 2013 7:32:41 PM UTC-8, Massimo Di Pierro wrote:
I agree. We'll look into it.
On
From the man himself... excellent. Thank you, Massimo.
On Monday, December 16, 2013 8:05:23 PM UTC-8, Massimo Di Pierro wrote:
You can make a group buyers and they buy something
auth.add_membership(role=buyers) then check permissions with
@auth.requires_membership(buyers)
or explicitly
You don't need the grid for that -- just use a SQLFORM:
form2 = SQLFORM(db.Participant, fields=fields).process()
Anthony
On Friday, December 13, 2013 11:38:03 AM UTC-5, LaDarrius Stewart wrote:
Is there to only give the add(create) functionality of the sqlform.grid
Example:
This would seem to be the same issue as
https://groups.google.com/d/topic/web2py/kyEYmfQs6L0/discussion but yet
the solution offered there (make sure you've got the latest web2py.js)
doesn't seem to be working for me. Oddly, I've got another form being
loaded with LOAD(ajax=True) on the same
I have [uwsgi-cron] command python /var/www/web2py/web2py.py -Q -S
welcome -M -R scripts/sessions2trash.py -A -o registered as cron task in
my uwsgi log (because the cron is mentioned in the config file for uwsgi.
Under which user/how can I really see this cron entry?
--
Resources:
-
I am trying to create an application using web2py backend that is fully
AJAX. I amusing the jQuery/Javascript to create a client. Now am a bit
stuck on the customising the behavior @auth.requires_login() decorator.
I have a jQuery request to an action with a @auth.requires_login()
decorator:
Try check with the google chrome js console. It should tell you what is
going on.
On Monday, 16 December 2013 23:44:23 UTC-6, Brian M wrote:
This would seem to be the same issue as
https://groups.google.com/d/topic/web2py/kyEYmfQs6L0/discussion but yet
the solution offered there (make
54 matches
Mail list logo