[web2py] Re: web2py with alchemy

2010-02-14 Thread mdipierro
not correct. web2py DAL does not use SQLAlchemy. On Feb 13, 6:48 pm, waTR r...@devshell.org wrote: I believe the DAL is originally just another layer on top of SQLAlchemy. So I would think you could use it extremely easily. Check the code in the dal python file and see how they imported the

[web2py] Re: URL and URLs

2010-02-14 Thread mdipierro
We could create a switch in routes that allows to change the URL validation regex. I would take a patch. I would not change the default though. On Feb 13, 4:48 pm, Jonathan Lundell jlund...@pobox.com wrote: On Feb 13, 2010, at 2:16 PM, DenesL wrote: 1) Is that the only reason? So there is

[web2py] Re: web2py site problem ?!

2010-02-14 Thread mdipierro
I wanted to experience with EC2 anyway. I agree for my needs it may very well be overkill. Thanks for the pointer. On Feb 13, 6:26 pm, villas villa...@gmail.com wrote: Massimo, When I tried EC2 it was very time-consuming and the backups were difficult and I was just wasting time. In the end

[web2py] Execute file in web2py environment fails with cron

2010-02-14 Thread Thadeus Burgess
When running the command below everything works fine, the python file executes correctly. thadeus$ /usr/bin/python /web2py/web2py.py -S MYAPP -M -R /web2py/applications/MYAPP/cron/update_records.py /web2py/applications/MYAPP/cron/cron.log This works great when running from bash, however when I

[web2py] Re: On the online book

2010-02-14 Thread mdipierro
I really really appreciate this. Somehow the chipin widget is not updated in real time but I do get the notifications from paypal. Massimo On Feb 13, 5:31 pm, villas villa...@gmail.com wrote: On Feb 13, 11:14 pm, Richard richar...@gmail.com wrote: I had no idea you were getting that much

[web2py] modular layout

2010-02-14 Thread salbefe
Hello, I need to built a left sidebar from a database. In the main layout file I have the following code: div class=unit div class=container {{include 'default/leftsidebar.html'}} /div /div

[web2py] Re: first gae app

2010-02-14 Thread Richard
sounds like this will be useful. StringListProperty is a native gae type now supported by web2py: http://code.google.com/appengine/docs/python/datastore/typesandpropertyclasses.html#StringListProperty http://groups.google.com/group/web2py/browse_thread/thread/7d284c9fa488e855 To get around the

[web2py] Re: modular layout

2010-02-14 Thread salbefe
Another question I would like a put a calendar on my website. div class=unit div class=container {{include 'default/calendar.html'}} /div /div I know how to generate a calendar in python with html but is not clear to me if I need a controller and then I should pass the

[web2py] fcgi problem

2010-02-14 Thread hamdy.a.farag
Hi I've problems running web2py with nginx webserver and fcgi I'm brandy new to this and the tutorial I found talks about lighttpd web server so any hints about that ? -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send

[web2py] Re: onvalidation problem

2010-02-14 Thread hamdy.a.farag
I posted the code on private -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com. For more options, visit

Re: [web2py] Re: On the online book

2010-02-14 Thread Albert Abril
I bought the pdf two months ago. Now i contributted with 5$, isn't so much, but i'm still studying, there's my contributtion to the cause. I aprreciate the effort you're doing on that. regards! On Sun, Feb 14, 2010 at 9:15 AM, mdipierro mdipie...@cs.depaul.edu wrote: I really really

[web2py] Re: modular layout

2010-02-14 Thread mdipierro
There are two types of frameworks. push and pull. In the pull frameworks, the url maps into a view and the view calls multiple controller actions. In the push, the url maps into one controller action which renders one ore more views. web2py (as well as Django, Pylons, and Rails) are push. The

[web2py] Re: modular layout

2010-02-14 Thread mdipierro
If you are not loading a page subset via ajax. Then your view includes another view, your one and only controller must generate all the variables needed by both views. On Feb 14, 5:54 am, salbefe salb...@gmail.com wrote: Another question I would like a put a calendar on my website. div

[web2py] Re: URL and URLs

2010-02-14 Thread DenesL
It seems that using LOCALE in the regex would do the job but setting locale is a big can of worms. On 14 feb, 03:04, mdipierro mdipie...@cs.depaul.edu wrote: We could create a switch in routes that allows to change the URL validation regex. I would take a patch. I would not change the default

[web2py] Re: Execute file in web2py environment fails with cron

2010-02-14 Thread John Heenan
Get rid of the standard output redirect and append symbol for shell use, '', in your crontab. Cron jobs do not use a shell. Standard output is passed back to web2py and will appear in your web2py logs. John Heenan On Feb 14, 6:13 pm, Thadeus Burgess thade...@thadeusb.com wrote: When running the

[web2py] Re: Execute file in web2py environment fails with cron

2010-02-14 Thread mdipierro
I think your crontab should just be */1 * * * * user *cron/update_records.py On Feb 14, 2:13 am, Thadeus Burgess thade...@thadeusb.com wrote: When running the command below everything works fine, the python file executes correctly. thadeus$ /usr/bin/python /web2py/web2py.py -S MYAPP -M

[web2py] Re: Execute file in web2py environment fails with cron

2010-02-14 Thread mdipierro
I think your crontab should just be */1 * * * * user * /web2py/applications/MYAPP/cron/ update_records.py On Feb 14, 9:42 am, mdipierro mdipie...@cs.depaul.edu wrote: I think your crontab should just be */1 * * * *   user  *cron/update_records.py On Feb 14, 2:13 am, Thadeus Burgess

[web2py] one cool website

2010-02-14 Thread mdipierro
This is one cool web site made with web2py http://www.albendas.com -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this group, send email to

Re: [web2py] Re: URL and URLs

2010-02-14 Thread Jonathan Lundell
On Feb 14, 2010, at 12:04 AM, mdipierro wrote: We could create a switch in routes that allows to change the URL validation regex. I would take a patch. I would not change the default though. We should revisit the logic (btw, is this something we could do on the dev list instead?)

[web2py] Re: modular layout

2010-02-14 Thread salbefe
Thank you Massimo, {{=LOAD('default','sidebar',ajax=True)}} has solved my problem. Thanks a lot On 14 feb, 16:01, mdipierro mdipie...@cs.depaul.edu wrote: If you are not loading a page subset via ajax. Then your view includes another view, your one and only controller must generate all the

[web2py] Re: URL and URLs

2010-02-14 Thread mdipierro
Yes, let' move this to web2py_developers. On Feb 14, 11:26 am, Jonathan Lundell jlund...@pobox.com wrote: On Feb 14, 2010, at 12:04 AM, mdipierro wrote: We could create a switch in routes that allows to change the URL validation regex. I would take a patch. I would not change the default

[web2py] how to deploy web2py for a single app?

2010-02-14 Thread pistacchio
hi, i have my application in the standard directory /applications/myapp i'm deployig it in a production env (webfaction) using its web2py script. once set its routes, i can access my applications like myaccount.webfactional.com/myapp, but i'd like to have it like the root application. how can i

Re: [web2py] Re: Execute file in web2py environment fails with cron

2010-02-14 Thread Thadeus Burgess
I can't stress this enough. This exact same line in the system crontab (I just copied and pasted over to the new server and changed the paths) works perfectly on one server running web2py 1.73.1. -Thadeus On Sun, Feb 14, 2010 at 12:54 PM, Thadeus Burgess thade...@thadeusb.com wrote: You

[web2py] Re: one cool website

2010-02-14 Thread Yarko Tymciurak
On Feb 14, 10:19 am, mdipierro mdipie...@cs.depaul.edu wrote: This is one cool web site made with web2py  http://www.albendas.com It is indeed nice - the main page doesn't load at all (black browser screen) in Google Chrome / Linux (at least the 64bit version, which _is_ in beta - and the 64

[web2py] Re: adding additional elements to custom form while leaving rest untouched

2010-02-14 Thread selecta
I want it too look like the default rendering of {{=form}} - I just want an easy solution. I looked into the document but it only tells how to customize each and every element. I don't want that, I just want to start the form, display some custom stuff then show the main part of the form (table

[web2py] Re: plug-in webfolder

2010-02-14 Thread villas
On Jan 29, 9:38 am, selecta gr...@delarue-berlin.de wrote: It depends on an improved IS_IN_SET validator. To use the plug-in you need to replace the constructor of IS_IN_SET (gluon/validators.py) Hi Selecta, I like the plugin! However, I am not so happy to modify validators.py. I suggest:

[web2py] Re: adding additional elements to custom form while leaving rest untouched

2010-02-14 Thread villas
Hi selecta Maybe you mean manually adding an element like this: form[0].insert(TR(...), _id='inserted_table_row') -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from

[web2py] Re: plug-in webfolder

2010-02-14 Thread selecta
with version 1.74.11 and above you do not need to modify validator.py :) .. will fix the missing import, thx On Feb 14, 9:35 pm, villas villa...@gmail.com wrote: On Jan 29, 9:38 am, selecta gr...@delarue-berlin.de wrote: It depends on an improved IS_IN_SET validator. To use the plug-in you

[web2py] Re: plug-in webfolder

2010-02-14 Thread selecta
ok it's fixed @villas: If you liked that I'm sure you will like some of the more advances plug-ins that I am currently developing and planing :) On Feb 14, 9:46 pm, selecta gr...@delarue-berlin.de wrote: with version 1.74.11 and above you do not need to modify validator.py :) .. will fix the

[web2py] Re: plug-in webfolder

2010-02-14 Thread villas
with version 1.74.11 and above you do not need to modify validator.py :) Ah! I couldn't find any instructions except your old post. Thanks. D -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to

[web2py] Re: Execute file in web2py environment fails with cron

2010-02-14 Thread mdipierro
I see. Thry this then: */1 * * * * /usr/bin/python /web2py/web2py.py -S MYAPP -M -N -R /web2py/applications/MYAPP/cron/update_records.py /web2py/applications/MYAPP/cron/cron.log notice -N in 1.73.1 hardcorn was not working for you. Now that it is working unix cron calls you script wich calls

[web2py] Re: adding additional elements to custom form while leaving rest untouched

2010-02-14 Thread selecta
Ah no that won't work since the extra elements are in a different HTML table. I really need form starts table with data and switches (custom) inner sqlfom here ({{=form}} without start and close) form close On Feb 14, 9:44 pm, villas villa...@gmail.com wrote: Hi selecta Maybe you mean

[web2py] how to display date and time nicely?

2010-02-14 Thread selecta
This is not 100% web2py related but I am sure if this will be answered many of you will profit at some point from it. Is there a python module that helps you to display dates and times nice e.g. just now (for within the last 5 minutes) 2 hours ago 2 days ago 15th February 2009 ... I guess

[web2py] Re: how to display date and time nicely?

2010-02-14 Thread mdipierro
Put this in a model def prettydate(d): try: dt = request.now - d except: return '' if dt.days=365*2: return '%s years ago' % int(dt.days/365) elif dt.days=365: return '1 years ago' elif dt.days=60: return '%s months ago' %

[web2py] Re: one cool website

2010-02-14 Thread Richard
on Chrome Linux 32 bit all I get is an animation at the centre. On Feb 15, 6:37 am, Yarko Tymciurak resultsinsoftw...@gmail.com wrote: On Feb 14, 10:19 am, mdipierro mdipie...@cs.depaul.edu wrote: This is one cool web site made with web2py  http://www.albendas.com It is indeed nice -

[web2py] Re: adding additional elements to custom form while leaving rest untouched

2010-02-14 Thread DenesL
Just insert your table in the form: form.insert(0,your_table) and in the view use {{=form}} On 14 feb, 16:01, selecta gr...@delarue-berlin.de wrote: Ah no that won't work since the extra elements are in a different HTML table. I really need form starts table with data and switches

Re: [web2py] Re: Execute file in web2py environment fails with cron

2010-02-14 Thread Thadeus Burgess
Adding -N does not fix it. Only the following happens: =web2py Enterprise Web Framework =Created by Massimo Di Pierro, Copyright 2007-2010 =Version 1.74.11 (2010-02-03 10:53:34) =Database drivers available: SQLite3, PostgreSQL Still works if executed from bash. It is the users crontab file

[web2py] Re: Execute file in web2py environment fails with cron

2010-02-14 Thread mdipierro
can you print os.getcwd() to see in which folder it is being executed? On Feb 14, 9:04 pm, Thadeus Burgess thade...@thadeusb.com wrote: Adding -N does not fix it. Only the following happens: =web2py Enterprise Web Framework =Created by Massimo Di Pierro, Copyright 2007-2010 =Version

[web2py] Re: adding additional elements to custom form while leaving rest untouched

2010-02-14 Thread Yarko Tymciurak
On Feb 14, 3:01 pm, selecta gr...@delarue-berlin.de wrote: Ah no that won't work since the extra elements are in a different HTML table. I really need form starts table with data and switches (custom) inner sqlfom here ({{=form}} without start and close) form close Maybe what you really

Re: [web2py] Re: Execute file in web2py environment fails with cron

2010-02-14 Thread Thadeus Burgess
/web2py -Thadeus On Sun, Feb 14, 2010 at 10:30 PM, mdipierro mdipie...@cs.depaul.edu wrote: can you print os.getcwd() to see in which folder it is being executed? On Feb 14, 9:04 pm, Thadeus Burgess thade...@thadeusb.com wrote: Adding -N does not fix it. Only the following happens:

[web2py] DAL integer length

2010-02-14 Thread Kevin Bowling
How can I force the DAL to use a 64-bit integer length (BIGINT) per facebook requirements for storing UIDs? -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this

[web2py] Re: how to display date and time nicely?

2010-02-14 Thread selecta
:) On Feb 15, 12:54 am, mdipierro mdipie...@cs.depaul.edu wrote: Put this in a model def prettydate(d):     try:         dt = request.now - d     except:         return ''     if dt.days=365*2:         return '%s years ago' % int(dt.days/365)     elif dt.days=365:         return '1