[web2py] Getting Started...

2010-12-25 Thread David J
I recently started looking into web2py vs Django which I have been using for the past few years. I like this framework it seems very clean and simple; However, I am little confused about getting started using a remote server; It seems to tighten security web2py does not enable remote admin functi

Re: [web2py] Getting Started...

2010-12-25 Thread David J.
Thanks. so if I start on my local machine; Do I just start in my web2py root directory? Do I have to use the web interface to create apps or can I just run some sort of "bootstrap" script that loads all the same stuff into a new project directory? I see the "welcome" app is zipped or someth

Re: [web2py] Getting Started...

2010-12-25 Thread David J.
On a mac; I was wondering if Could just create a folder in the web2py root and start from there? On 12/25/10 11:47 PM, pbreit wrote: On Mac or windows, just double-click the app. Maybe on *nix as well. Best to create the project in admin but after that you can do *all* of your editing in t

Re: [web2py] Getting Started...

2010-12-25 Thread David J.
Thanks; I am slowly understanding it. I created an app called app1; seems like when I go to the url localhost:8000/app1/default/index it redirects me to the welcome app? I saw somewhere that the welcome app is the "Default" app; wondering why its not finding the app when I try the url? Tha

Re: [web2py] Getting Started...

2010-12-26 Thread David J.
s for your help. On 12/26/10 10:18 AM, Anthony wrote: On Sunday, December 26, 2010 12:05:59 AM UTC-5, David J wrote: Thanks; I am slowly understanding it. I created an app called app1; seems like when I go to the url localhost:8000/app1/default/index it redirects me to

[web2py] Default Values.

2010-12-26 Thread David J.
How do I specify Default DB values; ie: I have a db field created_at which is datetime and should be a timestamp of when the user was created. Normally in mysql; we use "created_at timestamp default now()" where do I specify this default value? Or do I specify it when I create the object?

Re: [web2py] Default Values.

2010-12-26 Thread David J.
now), Field <http://web2py.com/book/default/docstring/Field>('updated_by',db.auth_user,update=auth.user_id)) http://web2py.com/book/default/chapter/06#Table-Inheritance 2010/12/26 David J. mailto:da...@styleflare.com>> How do I specify Default DB values; ie: I h

Re: [web2py] Default Values.

2010-12-26 Thread David J.
Thanks for the Tips; Does this have sqlite have some sort of limitations? I seem to get this exception; Traceback (most recent call last): File "/Users/book/Desktop/python-projects/web2py/gluon/restricted.py", line 188, in restricted exec ccode in environment File "/Users/book/Deskt

Re: [web2py] Ajax pattern with Web2py

2010-12-27 Thread David J.
Hey Markus; I am questioning the same thing; I am also trying to dig up this information. maybe someone on this list has dealt with similar problems and wouldn't mind sharing? If I find something I will be sure to post. Thanks. On 12/27/10 10:54 AM, Markus Schmitz wrote: Good afternoon

Re: [web2py] SQLFORM into a pop window

2010-12-28 Thread David J.
Can I have a peek at the app also? I am trying to get this working as well. Thanks. On 12/28/10 1:37 AM, Kenneth Lundström wrote: Thank you Bruno, my first thought when I tested it was that this doesn´t work at all, but now I see that it works quite nice. Kenneth Attached is an app whi

[web2py] FORM Generation Code.

2010-12-29 Thread David J.
Where is the code that Generates the FORMs? What is the best way to modify this; Currently when it outputs the key name It puts a colon; ex. "First Name:" instaead of just "First Name" I simply want to remove that from the form. Also on the links of the welcome app; That generate the "[ login

Re: [web2py] FORM Generation Code.

2010-12-29 Thread David J.
quot; Thanks. On 12/29/10 2:02 PM, Bruno Rocha wrote: you can set labels to auth_user table db.auth_user.first_name.label = 'F Name' db.auth_user.last_name.label = 'WHATEVER' If you mean extra link in login/register form, simply edit /views/default/user.html 2010/12

Re: [web2py] FORM Generation Code.

2010-12-29 Thread David J.
e: you can set labels to auth_user table db.auth_user.first_name.label = 'F Name' db.auth_user.last_name.label = 'WHATEVER' If you mean extra link in login/register form, simply edit /views/default/user.html 2010/12/29 David J. mailto:da...@styleflare.com>>

[web2py] creating a new form RENDERER.

2010-12-30 Thread David J.
What is the best way to create a new FORM renderer? How can I override or add a new form render type, ie instead of "table|div|ul"? Thanks.

Re: [web2py] Re: creating a new form RENDERER.

2010-12-30 Thread David J.
wrow in newrows: table.append(newrow) perhaps we can make this more general? On Dec 30, 1:59 pm, "David J." wrote: What is the best way to create a new FORM renderer? How can I override or add a new form render type, ie instead of "table|div|ul"? Thanks.

Re: [web2py] Re: comet for web2py (give it a try) - and happy new year

2010-12-31 Thread David J.
Setting up right now. I need trunk web2py_ajax or will latest work? Can I just copy that single file from trunk? Thx. On 12/31/10 2:21 PM, mdipierro wrote: ... and this requires the latest web2py_ajax.html from welcome in trunk else it does not work. Please give it a try, I have not tested i

Re: [web2py] jQuery - need help !

2011-01-03 Thread David J
I think you don't have the full jquery ui package. I see you have custom On Jan 3, 2011 9:45 AM, "Martin Weissenboeck" wrote: > Hi, > I want to use jQuery UI. I have tried a lot of things during the last two > days, but nothing worked. > I have read http://jqueryui.com/docs/Getting_Started and I

[web2py] Multi Tabbed Menu - Any Suggestions.

2011-01-05 Thread David J.
I was wondering if anyone on the list has seen an good multi-level horizontal tab menu. I have Company Overview Our People Products Product 1 Product 2 Obviously the second layer is visible on the "selected" tab. I was hoping there might be something already made that does this.

Re: [web2py] Re: Is there a way to remove application name from URL()?

2011-01-17 Thread David J.
The easy way is to use "init" as your application name; It uses that by default. HTH. On 1/17/11 4:11 PM, howesc wrote: i'm pretty sure there is a section in the book that covers this topic exactly. there is also new versions of routing since i last wrote this. anyhow, my routes info: r

[web2py] Cached Results Using a Module.

2011-01-19 Thread David J.
Perhaps I missed an important point; I have an "api.py" which I loaded through the modules directory; This "api.py" makes calls for data to external web services; In my controller; I have api = local_import('api') def remote(): api_result = api.xml_request({'id':'123456'}) return

Re: [web2py] Re: Cached Results Using a Module.

2011-01-19 Thread David J.
Great Thanks I will try; At what cost am I doing this; Does it add tremendous overhead? Thanks On 1/19/11 5:24 PM, ron_m wrote: If you are editing the file in the modules directory then that is the problem. A module gets pulled in and kept by the server until restart unless you add a parame

Re: [web2py] Re: Cached Results Using a Module.

2011-01-19 Thread David J.
As you said; It worked; Thanks for the pointer; I appreciate it; And will set to false in production. Thanks again. On 1/19/11 5:27 PM, Massimo Di Pierro wrote: Yes. In production set the second argument to False On Jan 19, 4:27 pm, "David J." wrote: Great Thanks I will try

Re: [web2py] Another question about Powertable

2011-01-21 Thread David J.
Have you tried returning your rows using an SQL order by clause to see if that worked... Just a suggestion; I never used powertable. On 1/21/11 10:29 AM, Kenneth Lundström wrote: Hi again Bruno, another stupid question about powertable. How do I select in what order the rows are shown. For

[web2py] Adding fields to the default register form;

2011-01-25 Thread David J.
How can I extend the default register form to add custom fields? I am not extending the Database; I just want to append more fields for validation. Thanks.

Re: [web2py] Adding fields to the default register form;

2011-01-25 Thread David J.
tom form syntax. The only caveat is that the displayed form depends on the value of |request.args(0)| therefore you may need if statement like this: On 1/25/11 8:24 AM, contatogilson...@gmail.com wrote: http://web2py.com/book/default/chapter/08#Customizing-Auth ______

Re: [web2py] Adding fields to the default register form;

2011-01-25 Thread David J.
in /applications/welcome/views/default/. It's a view file, so it's in the 'views' folder. Anthony On Tuesday, January 25, 2011 8:47:25 AM UTC-5, David J wrote: Thanks But I am confused by this; I am using the welcome app; I dont see these files (sample view d

[web2py] Add objects through Shell not committing;

2011-01-25 Thread David J.
I am trying to add objects from the shell The objects are static so I didnt feel the need to make any web interface for it; python ./web2py.py -S app -M -P Interactive shell>> db.numbers.insert(number='100'); 1 db.numbers(0).number 100 This all works; I exit out of shell and then go back i

[web2py] Escaping entities.

2011-01-26 Thread David J.
How do I display HTML entities; ie; © Copyright I am doing response.title = '© Copyright 2011'; I see that text exactly in the title bar; I should see "© Copyright 2011" Thanks

[web2py] Overwriting the default "register" action

2011-01-26 Thread David J.
Currently I have a session variable called site_id; Its a read only variable we set when the user comes to one of the sites; ON the default register pages; I am trying to store this variable when the user registers; I am trying to figure out how to "extend" the default "register" command; B

Re: [web2py] Re: Adding fields to the default register form;

2011-01-27 Thread David J.
The fact that auth is so tightly coupled with the view is very frustrating; It would be better if auth return an object that was wrappable; in FORM(); rather than the rendered form This way you can do things like addfield() to the form before it is rendered or just render it as it is; I as

[web2py] Possible DB bug on update;

2011-01-27 Thread David J.
I am using 1.9.1.4 I see a strange behavior I am doing this simple test; def update(): rows = db((db.nums.hold==False) & (db.nums.active==False)).select() for row in rows.find(lambda row: row.num[len(row.num)-2:]=='55'): row.update(hold=True) db.commit() return loca

Re: [web2py] Re: Possible DB bug on update;

2011-01-27 Thread David J.
Darn; I missed that; Thanks for the help; I really thought I read the chapter through. Thanks. On 1/27/11 11:44 PM, ron_m wrote: >From the DAL chapter of the manual |update_record| update_record web2py also allows updating a single record that is already in memory using |update_re

[web2py] Disabling the error page in production.

2011-01-28 Thread David J.
How do I disable the error page in production? I would ideally like to replace it with a Nicer page same for 404 errors; I searched the book for error page; but I must have missed the part where it says disabling. Thanks.

[web2py] Forcing SSL on certain requests;

2011-01-29 Thread David J.
Is there a utility available to force requests to SSL? (ex: Login, Register, etc..) I see one option in reCaptcha section; use_ssl=True But I looked in the FORM docs and don't see that as an option;

Re: [web2py] Forcing SSL on certain requests;

2011-01-30 Thread David J.
Philip; Yes; I suppose that would work; Thanks for the advice; It is appreciated. Have a good day. On 1/30/11 2:41 AM, Philip Kilner wrote: Hi David, On 30/01/2011 01:02, David J. wrote: Is there a utility available to force requests to SSL? (ex: Login, Register, etc..) Are you

Re: [web2py] Web2Py on Raspberry Pi?

2012-07-12 Thread David J
For sure. You can probably run the embedded rocket webserver On Jul 12, 2012 7:29 PM, "Ron K Jeffries" wrote: > Raspberry Pi is an inexpensive $35 ARM based Linux board that has 256MB of > RAM and Ethernet as network connectivity. > They are shipping in volume, maybe a million by end of 2012. > >

Re: [web2py] Re: Auth form custom errors

2012-05-07 Thread David J
You have a typo "acton" On May 7, 2012 7:32 AM, "Rhys" wrote: > Hey Massimo, > > The > > {{form=auth()}} > {{form['_acton'] = "/user/login"}} > {{=form.custom.begin}} > > > spat out the html without the updated action > > > > > Cheers, > > Rhys > > > On Monday, May 7, 2012 12:52:20 AM UTC+10, Ma

Re: [web2py] Re: error class proposal

2012-01-17 Thread David J
Massimo added this to trunk. Please see .inputinvalid class On Jan 17, 2012 8:47 PM, "Alex" wrote: > I've created a function getFormFields which I call for every form I'm > using. In this function I go through all inputs of the form with > form.elements('input, select, textarea') > > and then I

Re: [web2py] Re: web2py with twitter bootstrap - very clean interface ...

2012-01-24 Thread David J
Yeah setup bs2 today and its really sweet. Just need to make some class changes from v1.4 On Jan 24, 2012 6:47 PM, "pbreit" wrote: > Looks like Twitter Bootstrap 2 is ready. I've seen some positive comments > about it in regards to the switch to 12 columns and responsiveness.

Re: [web2py] auth

2012-02-23 Thread David J
Yes please look in docs. On Feb 23, 2012 5:33 AM, "Prakhar Srivastava" wrote: > is there any way to change the path after Login by default in direct > to the index >

Re: [web2py] Re: password storage with per-user salt

2011-09-21 Thread David J
Why double salt. That's the point of SSL. we should only be concerned with application level details not transport On Sep 21, 2011 10:27 AM, "Anthony" wrote: > Yes, I think the salting and hashing we're discussing is meant to protect > the passwords once on the server (i.e., if the server/database

[web2py] Returning the Row after insert;

2011-01-31 Thread David J.
currently; I am doing a select after an insert to look up the values of a row; For example; the registration key when using the default "register" application; But I think there must be an easier way; If anyone has a "best practice" suggestion I would appreciate it; currently the code looks

[web2py] onaccept after user registers;

2011-02-02 Thread David J.
Is there an example of using "onaccept" after a user registers?

Re: [web2py] Re: Cloud hosting company

2011-02-07 Thread David J.
You can run on Rackspace cloud as well; On 2/7/11 11:32 AM, stargate wrote: Where is the prices on hosting? On Feb 7, 11:10 am, Bruno Rocha wrote: I am running in dotcloud (but it is in beta) http://www.web2py.dotcloud.com/ also Pydra is announcing they w

[web2py] Overriding the Default "verify_email"

2011-02-07 Thread David J.
I was wondering how I can execute a custom action on "verify_email" I have an external system that I want to notify once a user has confirmed their email address; Thanks.

[web2py] onaccept

2011-02-07 Thread David J.
Is there an example of how to use "onaccept" handler? I tried auth.settings.verify_email_onaccept = lambda f:_create_account(f) def _create_account(f): session.account = f return I tried on my index page to display {{= session.account }} But I dont think it worked. Thanks.

[web2py] URL secure flag.

2011-02-08 Thread David J.
I was wondering why URL does not include a secure flag? I think it should be able to set "secure" url's For example if you do URL("function",secure=True) We generate a complete URL https://example.com/welcome/default/function

Re: [web2py] Re: URL secure flag.

2011-02-08 Thread David J.
have a URL(,sign=) option to digitally sign URLs. On Feb 8, 12:58 pm, "David J." wrote: I was wondering why URL does not include a secure flag? I think it should be able to set "secure" url's For example if you do URL("function",secure=True) We generat

Re: [web2py] Re: URL secure flag.

2011-02-08 Thread David J.
Thanks Jonathan; This works too; Thanks; On 2/8/11 3:11 PM, Jonathan Lundell wrote: On Feb 8, 2011, at 11:41 AM, David J. wrote: Well than maybe someone could inform them; ;) It would be useful; My current work around is to make the whole site secure cringe; If you know that the host

Re: [web2py] Re: URL secure flag.

2011-02-08 Thread David J.
inks could at least be written so that you can switch between the two rather easily; for example on login; you would probably always want that using https On 2/8/11 3:59 PM, Jonathan Lundell wrote: On Feb 8, 2011, at 12:24 PM, David J. wrote: Thanks Jonathan; This works too; Good. This *co

Re: [web2py] auth.signature

2011-02-08 Thread David J.
This is long overdue; although it was in the book; I was using the default auth_user table; I really dont know when the user was registered? Whoops; this will solve this problem Thanks. On 2/8/11 4:04 PM, Bruno Rocha wrote: 2011/2/8 pbreit mailto:pbreitenb...@gmail.com>> Hmmm, still d

Re: [web2py] Kind of e-commerce but maybe not

2011-02-08 Thread David J.
The other problem your going to have is Peripheral support; They are probably going to want to work with cash drawer, printers and scanners. I am not sure how well the browser can interact with those things. It would be nice to try I personally would love to make a POS work with web2py O

[web2py] Additional Queries on Login.

2011-02-08 Thread David J.
I am using the default web2py login mechanism; I am not sure where I can run additional queries after a successful login? I tried doing def load_settings(f): settings = db.settings(db.settings.user == f.id) session.settings = settings return auth.settings.login_onaccept = lambda

Re: [web2py] Re: Additional Queries on Login.

2011-02-09 Thread David J.
() auth.settings.login_onaccept = lambda form:load_settings(form) On Feb 8, 11:33 pm, "David J." wrote: I am using the default web2py login mechanism; I am not sure where I can run additional queries after a successful login? I tried doing def load_settings(f): settings = d

Re: [web2py] Re: URL secure flag.

2011-02-09 Thread David J.
e the patch. I'll work one up. Input on the exact argument syntax is welcome. On Feb 8, 2:59 pm, Jonathan Lundell wrote: On Feb 8, 2011, at 12:24 PM, David J. wrote: Thanks Jonathan; This works too; Good. This *could* be an option to URL, since it has internal access to request. Sup

Re: [web2py] Re: how may I do this (block and unblock buttons for admin dashboard)

2011-02-09 Thread David J.
I was wondering about that too;; Is BUTTON a new addition? I didn't see it in the docs; On 2/9/11 3:24 PM, Richard Vézina wrote: Get it to work like this in view.py : {{=T('block access')}} Thanks Massimo Is BUTTON helper in trunk?? Richard On Wed, Feb 9, 2011 at 3:17 PM, Richard Vézi

Re: [web2py] Re: URL secure flag.

2011-02-09 Thread David J.
So then we would use scheme='https' for secure and forget the secure flag? On 2/9/11 6:26 PM, Jonathan Lundell wrote: On Feb 9, 2011, at 2:54 PM, Jonathan Lundell wrote: On Feb 9, 2011, at 2:24 PM, Anthony wrote: Do we want to handle websocket URLs as well (i.e., ws and wss schemes instead o

Re: [web2py] Re: URL secure flag.

2011-02-09 Thread David J.
Is the code available in the repo yet? On 2/9/11 6:37 PM, Jonathan Lundell wrote: On Feb 9, 2011, at 3:34 PM, David J. wrote: So then we would use scheme='https' for secure and forget the secure flag? Right. It's a little more general, since 'secure' could also im

Re: [web2py] custom form without using database?

2011-02-10 Thread David J.
Side Question; How can you add validators this way? On 2/10/11 7:37 AM, Bruno Rocha wrote: >>> form = FORM() >>> form.element().append(LABEL(_for='name',_value='Name')) >>> form.element().append(INPUT(_type='text',_name='name')) >>> print form for="name" value="Name"> --- Bruno Rocha http://

[web2py] change_password form

2011-02-10 Thread David J.
I noticed that the change password form is not obeying the "formstyle" value in gluon tools.py If you see the change_password() function you see form = form_factory( Field('old_password', 'password', label=self.messages.old_password, requires=validat

[web2py] Gluon tools.py - form style

2011-02-13 Thread David J
The change password and lost password forms are missing the "formstyle " attribute. If you look in gluon tools.py you see both methods call the form_factory, the last line of these 2 methods should be .",formstyle=self.settings.formstyle)" this way it maintains consistency between forms. Please co

Re: [web2py] Re: Gluon tools.py - form style

2011-02-14 Thread David J.
Not sure how to do that; If you could tell me so I know for the future. Thanks. On 2/14/11 10:38 AM, howesc wrote: the diff from trunk for what i think this change is attached david - do you mind adding this as a ticket in google code so that the code owners can track it? thanks, christi

Re: [web2py] Re: Gluon tools.py - form style

2011-02-14 Thread David J.
think you can add comments to the issue, which is good if you have a suggested fix etc. On Feb 14, 3:47 pm, "David J." wrote: Not sure how to do that; If you could tell me so I know for the future. Thanks. On 2/14/11 10:38 AM, howesc wrote: the diff from trunk for what i think this

Re: [web2py] using routes_onerror

2011-02-17 Thread David J.
I did notice one 'race' condition; If you have an app that has an error in models/db.py and you have */400 in routes.py your going to continuously be redirecting your self to the same page until the browsers own error handling kicks in and notifies of the problem; Because in any page load yo

Re: [web2py] Subclass navbar() ?

2011-02-21 Thread David J
You only have to override the methods you want to override. On Feb 20, 2011 11:43 PM, "pbreit" wrote: > I can't seem to figure out the correct way to subclass navbar(). Does this > look close? > > === db.y == > from gluon.tools import * > > class MyAuth(Auth): > > def __init__(self, environment,

Re: [web2py] Subclass navbar() ?

2011-02-21 Thread David J
Sorry didn't see it was answered. I apologize. On Feb 21, 2011 4:02 PM, "David J" wrote: > You only have to override the methods you want to override. > On Feb 20, 2011 11:43 PM, "pbreit" wrote: >> I can't seem to figure out the correct way to su

Re: [web2py] Dreampie as web2py shell

2011-02-21 Thread David J
Can't you just view the source if web2py.py in root directory? I would imagine if you add that if you add that to your python_path as well as all gluon you could accomplish that. On Feb 21, 2011 2:54 PM, "Bruno Rocha" wrote: > Hi, > > I am trying to use DreamPie [ http://dreampie.sourceforge.net/

Re: [web2py] Re: Status of Python 2.4 support

2011-02-27 Thread David J
I have a side question. Why couldn't you choose another hosting company? Why do people insist on using hosts that are so outdated? It can't be financially motivated. It seems like plenty of options are available for just under $10. On Feb 27, 2011 2:09 PM, "Russ" wrote: > Very good to know. Thanks

Re: [web2py] Log the user out

2011-03-01 Thread David J.
Ed you have to use session.flash; Anytime you redirect your not in request scope anymore so request.flash wont help; On 3/1/11 2:12 PM, Ed Greenberg wrote: At the end of my controller function, I'd like to log the user out and send him back to the login screen, hopefully with a response.fla

[web2py] Socket Error Using FCGI;

2011-03-03 Thread David J.
Traceback (most recent call last): File "/apps/web/web2py/gluon/contrib/gateways/fcgi.py", line 664, in run self.process_input() File "/apps/web/web2py/gluon/contrib/gateways/fcgi.py", line 700, in process_input self._do_params(rec) File "/apps/web/web2py/gluon/contrib/gateways/fcg

Re: [web2py] Re: Socket Error Using FCGI;

2011-03-03 Thread David J.
e? Do you find it in the logs or bothers users? On Mar 3, 3:29 pm, "David J." wrote: Traceback (most recent call last): File "/apps/web/web2py/gluon/contrib/gateways/fcgi.py", line 664, in run self.process_input() File "/apps/web/web2py/gluon/contr

Re: [web2py] Re: python tutorial video

2011-03-09 Thread David J.
No it not ok: I dont think that will be Massimo's intention; When he releases the update it will kept a BIG secret and he will not notify anyone; as he usually does! Only kidding; you will be the first to know! On 3/9/11 11:42 AM, Vinicius Assef wrote: Let us know when new version will be a

Re: [web2py] Mint 9 and Python2.7

2011-03-14 Thread David J.
Strange I just ran python 2.7 and it worked for me... On 3/14/11 6:54 PM, Erik Vandamme wrote: I've just downloaded both Python2.7 (and installed it) and Web2Py, then tried the python2.7 web2py.py -h and it says: it requires 2.5. or 2.6 under 2.6 nothing much more happens

Re: [web2py] Re: video about new RESTful APIs

2011-03-17 Thread David J.
For clarification; This gets put in the model code not controller code correct? So for example in "db.py" Thanks. On 3/17/11 3:58 PM, Massimo Di Pierro wrote: This is now in trunk. Some API changes are still possible. Right now it supports fiels of type, id, integer, double, date, datetime

Re: [web2py] How do I set web2py applications as separate virtualhosts?

2011-03-22 Thread David J.
Look at the routes; you can do this; Chapter 4 of the book. On 3/22/11 2:12 PM, Keith Pettit wrote: Web2py works great for me through Apache and mod_wsgi. All seems fast and clean. But now that I'm creating multiple web2py applications. How can I deploy multiple web2py applications as sep

Re: [web2py] Re: How do I set web2py applications as separate virtualhosts?

2011-03-22 Thread David J.
Look at the routes.py in chapter 4 of the book. I just did it this morning and it work using the that latest version of web2py (Know that you have to name the file routes.py even though its in the router.py.example; and you might think to name it router.py and thus think it does not work.)

Re: [web2py] static subdirectories

2011-03-22 Thread David J.
The former is semantically more correct; $user/app/controller/etc... It seems the domain is obviously the root of any app; then the "user" selected name should be the next logical level; then any functions that user has access to should be listed; On 3/22/11 2:12 PM, pbreit wrote: Would t

Re: [web2py] IS_INT_IN_RANGE Behavior in Database Example

2011-03-23 Thread David J.
I suppose to override; The example you gave would be pointless to have both; Clearly if you define it once at the model; then again in the controller; shouldn't the one define in the controller take precedence; How else would you override? On 3/23/11 11:45 AM, Jaunx wrote: In Example 29 of

Re: [web2py] Re: Lacking nginx deployment guide

2011-03-26 Thread David J.
I don't know about running web2py using uwsgi; However; When I run web2py with nginx I use the fastcgi module; I configure nginx like described in the stackoverflow article; except I use fastcgi; In nginx config I have location / { include fascgi_params; fastcgi_pass unix:/tmp/fcgi.s

[web2py] dashes in url

2011-03-31 Thread David J.
Seeing that using a "-" in function names is invalid in python; I was wondering how I define in my controller "get-started" url; If I define in my controller def get-started(): return dict() Its invalid; so I have to maybe use routes.py to rewrite it to just getstarted()? Is this the r

Re: [web2py] Re: dashes in url

2011-03-31 Thread David J.
Thanks I will try that; I get invalid request; but I will check again; perhaps I have a typo. On 3/31/11 10:31 AM, Ross Peoples wrote: web2py will automatically convert dashes to underscores for the function names, so: getting-started will become: def getting_started(): return dict()

Re: [web2py] Re: dashes in url

2011-03-31 Thread David J.
I checked this; I am using trunk; I am defining def get_started(): return dict() def features(): return dict() when I call /app/default/get-started I get invalid request; when I call /app/default/features It works perfectly; Maybe a bug? On 3/31/11 10:31 AM, Ross Peoples wrot

Re: [web2py] Re: dashes in url

2011-03-31 Thread David J.
I missed that calling app/default/get_started works also; On 3/31/11 10:31 AM, Ross Peoples wrote: web2py will automatically convert dashes to underscores for the function names, so: getting-started will become: def getting_started(): return dict()

Re: [web2py] Re: dashes in url

2011-03-31 Thread David J
Thanks I will rename router.py.example to routes.py in the web 2 py root and then I can also make a copy in my app to do specific routing? On Mar 31, 2011 10:58 AM, "Jonathan Lundell" wrote: > On Mar 31, 2011, at 7:46 AM, David J. wrote: >> >> I missed that >> >

Re: [web2py] Re: routing maps underscore to hyphens

2011-03-31 Thread David J.
That is correct; you can not use a hyphen in a python function name. On 3/31/11 12:18 PM, VP wrote: I am curious. I don't think people can define Python functions (controllers) that have hyphens. Right? If their controllers can not have hyphens, then why would web2py have to worry about mapp

Re: [web2py] Re: dashes in url

2011-03-31 Thread David J.
It is optional; read the router.py docs. Jonathan mentioned that in his post. On 3/31/11 12:24 PM, VP wrote: Unless I misunderstand the issue at hand here, seriously, I do not think this is web2py's scope to do this automatic mapping hyphens or dashes to underscores. Hyphen/dash is a minus s

[web2py] Setting secure in A

2011-03-31 Thread David J.
A while back I inquired about adding scheme to URL; It works great; Thank you; I was wondering if it could be added to 'A()' as well; (Unless I missed something in the docs; I need to set scheme to 'https';) I think this is important; For example in Auth() there is a helper method call 'navbar(

[web2py] Re: Setting secure in A

2011-03-31 Thread David J.
I made a mistake it is defined in the 'action' parameter; On 3/31/11 3:12 PM, David J. wrote: A while back I inquired about adding scheme to URL; It works great; Thank you; I was wondering if it could be added to 'A()' as well; (Unless I missed something in the docs; I n

Re: [web2py] Re: MongoDB and Web2Py

2011-04-01 Thread David J.
While DAL might not support MongDB; you can still use it via mongoengine; On 4/1/11 10:41 AM, Marcel Luethi wrote: Despite a lot of time, I'd like to help as well. MongoDB looks promising. On 1 Apr., 04:58, Massimo Di Pierro wrote: Lots of people asked for support but nobody volunteered

Re: [web2py] Re: MongoDB and Web2Py

2011-04-04 Thread David J.
Apr 1, 9:55 am, "David J." wrote: While DAL might not support MongDB; you can still use it via mongoengine; On 4/1/11 10:41 AM, Marcel Luethi wrote: Despite a lot of time, I'd like to help as well. MongoDB looks promising. On 1 Apr., 04:58, Massimo Di Pierro wrote: Lots o

Re: [web2py] New Slice: Create a Form Wizard

2011-04-04 Thread David J.
Just one issue; On step 2 it asks for email again; But email was already filled in... But the data is not in the form; Either the filed should be removed or the data should be there; The data does appear if you submit the form even if it is blank. On 4/4/11 4:06 PM, Bruno Rocha wrote: I

[web2py] Attribute Error

2011-04-10 Thread David J.
In my controller I am defining a class class Employee: pass john = Employee() # Create an empty employee record # Fill the fields of the record john.name = 'John Doe' john.dept = 'computer lab' john.salary = 1000 and in my view I am trying {{=employee.name}} It throws an attrib

[web2py] Re: Attribute Error - Passing Objects to View (Exception)

2011-04-10 Thread David J.
ou. David. On 4/10/11 5:53 AM, David J. wrote: In my controller I am defining a class class Employee: pass john = Employee() # Create an empty employee record # Fill the fields of the record john.name = 'John Doe' john.dept = 'computer lab' john.salary = 100

Re: [web2py] Re: Attribute Error

2011-04-10 Thread David J.
I am passing a list of employees so in my view I have {{ for n in employees:} {{= n.name }} {{pass}} On 4/10/11 9:10 AM, DenesL wrote: On Apr 10, 5:53 am, "David J." wrote: In my controller I am defining a class class Employee: pass john = Employee() # Creat

Re: [web2py] web2py posterity and mail man

2011-04-29 Thread David J.
Please check out experts4solutions.com for commercial projects. On 4/29/11 7:27 AM, yarden...@gmail.com wrote: Hi I need someone to help us setup on an Amazon web Services micro instance 1. web2py 2. mysql 3, postifx 4. posterity 5. mailman Will need to embed posterity and mailman into web2p

Re: [web2py] Re: MongoDBAdapter -- in DAL

2011-05-04 Thread David J.
Is this in trunk; I will start a new project today and use Mongo For DB I think I tried it last month and I had some problems; I didnt have the time to look into it. I will update and try again. Thanks. On 5/4/11 9:30 AM, Massimo Di Pierro wrote: fixing it now. Looks like not many people t

Re: [web2py] Re: MongoDBAdapter -- in DAL

2011-05-04 Thread David J.
tests before just to see; I am going to spend more time with it now and see what problems I run into; Thanks. On 5/4/11 10:30 AM, Massimo Di Pierro wrote: mongodb with DAL does not currently work but, if you help with tests, we could make it work On May 4, 8:56 am, "David J."

Re: [web2py] Re: Install sqlite3 driver for web2py

2011-05-04 Thread David J.
I am having the same issue; I think it is the python installation you can try on yours 'easy_install pysqlite' providing you have setuptools installed I am trying to rebuild my python from SRC. Not on solaris; Redhat. On 5/4/11 5:10 PM, PlanetUnknown wrote: Interesting.. On a plain pytho

[web2py] New Exception in Trunk.

2011-05-18 Thread David J.
I just upgraded my trunk; I get this exception S"('define_table argument is not a Field or Table: .first_name',)" Any ideas?

[web2py] Re: New Exception in Trunk.

2011-05-18 Thread David J.
= (int(vars.get(\'min\',0)),int(vars.get(\'max\',1000)))\n File "/apps/www/web2py.trunk/gluon/dal.py", line 4392, in __init__\n \'define_table argument is not a Field or Table: %s\' % field\nSyntaxError: define_table argument is not a Field or Tabl

  1   2   3   >