[web2py:25310] Re: Web2py is not too designer friendly?

2009-06-29 Thread Francois (Jersey)
An example of "return response.render('custom.html',data=data) " would be useful on the web2py website. Fabulous framework. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py Web Framework" group. To post to th

[web2py:25309] Re: maintain dictionary state between requests

2009-06-29 Thread mdipierro
I agree with has. You cache when multiple users need to access the same data. In you case the data is clearly associated to a user hence it belongs to a session. Massimo On Jun 29, 10:37 pm, Hans Donner wrote: > you should be able to also store the results in a cache. But perhaps > the session

[web2py:25308] Re: maintain dictionary state between requests

2009-06-29 Thread Hans Donner
you should be able to also store the results in a cache. But perhaps the session is better in this case On Tue, Jun 30, 2009 at 2:57 AM, Richard wrote: > > do you mean caching the database query? That might help, but > constructing the dictionary from the query also takes a lot of > operations. >

[web2py:25307] web2py control flow diagram

2009-06-29 Thread mdipierro
I just discovered www.websequencediagrams.com Here is a sample web2py diagram: http://www.websequencediagrams.com/cgi-bin/cdraw?lz=bm90ZSByaWdodCBvZiBCcm93c2VyOiBodHRwOi8vLi4uL2FjdGlvbgoAFActPlNlcnZlcjogSFRUUCBSZXF1ZXN0CgBCBW92ZXIgABkGLCBNb2RlbCxWaWV3LENvbnRyb2xsZXIsIERhdGFiYXNlOiB3ZWIycHkgKG11

[web2py:25306] Re: httpd.js (web server in javascript)

2009-06-29 Thread Yarko Tymciurak
a note about www.reversehttp.net/demos: I noticed on the tiniestdemo --- it will serve the value of the text box, and sets it to a default ("Hello from the tiniest demo") --- When I try to browse to http://tiniestdemo.www.reversehttp.net/ If I serve this text a few times, then change it (I addde

[web2py:25305] Re: datetime's sub-second information lost in SQLite/GAE

2009-06-29 Thread mdipierro
correction. not print statements on GAE but logging statetements. On Jun 29, 8:54 pm, mdipierro wrote: > In gluon/contrib/gql.py web2py does this: > >             if field.type == 'datetime' and value != None and not > isinstance(value, datetime.datetime): >                 (y, m, d) = [int(x) f

[web2py:25304] Re: datetime's sub-second information lost in SQLite/GAE

2009-06-29 Thread mdipierro
In gluon/contrib/gql.py web2py does this: if field.type == 'datetime' and value != None and not isinstance(value, datetime.datetime): (y, m, d) = [int(x) for x in str(value)[:10].strip().split('-')] time_items = [int(x) for

[web2py:25303] Re: datetime's sub-second information lost in SQLite/GAE

2009-06-29 Thread Dan
I think I see where this is happening in the /gluon/sql.py code. There are lines in that file that use this pattern, which truncates information about fractional seconds: datetime.isoformat()[:19] what is the best way to modify this behavior to retain the precision? (note that this pattern appea

[web2py:25302] Re: datetime's sub-second information lost in SQLite/GAE

2009-06-29 Thread Dan
Here is some sample code to produce the behavior I'm trying to describe. Note that in the controller, there are 2 lines commented out because they return an error ("TypeError: unsupported operand type(s) for -: 'str' and 'str'") db.define_table('timetest', db.Field('starttime','datetime',defa

[web2py:25301] Re: httpd.js (web server in javascript)

2009-06-29 Thread Yarko Tymciurak
well this is inevitable, I suppose; jquery doing it in javascript; opera doing in (?) I'll guess executable code, making a portable web services source, and traditional computing going small - twitter, iPhone, Android, etc. --- all these concerned with security on the open web, and wanting

[web2py:25300] Re: Permission to raise funds for web2py - friendly hi-tech business?

2009-06-29 Thread nathan.ms
Dave sounds very interesting. Point of information: there are very strict rules in the (at least in the US) for soliciting investment in this way and taking about potential profits. Google "rule 504 of regulation d". These rules are there to protect small investors and usually bar soliciting inves

[web2py:25299] Re: httpd.js (web server in javascript)

2009-06-29 Thread gluegl
Imagine a similar Opera UNITE... http://unite.opera.com/ New technology called Opera Unite, radically extending what you are able to do online. Opera Unite harnesses the power of today's fast connections and hardware, allowing all of us to help define the future landscape of the Web, one computer

[web2py:25298] datetime's sub-second information lost in SQLite/GAE

2009-06-29 Thread Dan
I'm using a datetime field with SQLite and GAE (different systems for development and deployment), and I can only get time resolution of 1 second when reading from the database. I know that I am working with information down to the 0.01 second resolution, and this is what I'm inserting into the da

[web2py:25297] Re: Using auth function (Approval)

2009-06-29 Thread Mico Siahaan
Thanks. Actually, I just uncommented line on default model.py, and in that file: auth.settings.registration_requires_approval = True I will set it to False then clear the registration keys. Other questions: 1. Can we rename the auth_user table to other for example to member table? 2. Can r

[web2py:25296] Re: maintain dictionary state between requests

2009-06-29 Thread Richard
do you mean caching the database query? That might help, but constructing the dictionary from the query also takes a lot of operations. On Jun 30, 1:11 am, Hans Donner wrote: > or store the data in cache? > > On Mon, Jun 29, 2009 at 3:43 PM, cjparsons wrote: > > > Session data is normally store

[web2py:25295] httpd.js (web server in javascript)

2009-06-29 Thread mdipierro
http://www.reversehttp.net/demos/ Not sure what to make of this but this is interest, for example as an alternative to heartbeats to check what a user is doing. Massimo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

[web2py:25294] Re: maintain dictionary state between requests

2009-06-29 Thread Richard
thanks for the explanation about what is happening behind the scenes. I think session should work well for me then. On Jun 29, 11:43 pm, cjparsons wrote: > Session data is normally stored on disk in the "sessions" folder in > python pickle format - only the session id is transferred over the >

[web2py:25293] Re: Permission to raise funds for web2py - friendly hi-tech business?

2009-06-29 Thread mdipierro
reading this again I incorrectly read the title as "[Permission to raise funds for web2py] [friendly hi-tech business?]" and did not understand it. then I read it again as "Permission to raise funds for [web2py-friendly] hi-tech business?" and now I understand your post. This is a tricky one.

[web2py:25292] Re: recaptcha and form_factory

2009-06-29 Thread mdipierro
oops, thanks On Jun 29, 6:34 pm, "mr.freeze" wrote: > Perfect.  BTW, I think you need to change line 172 of tools.py to: > self.errors['captcha'] = self.error_message > instead of: > self.errors['captcha'] = 'invalid!' > > It returns 'invalid!' even if you set error_message > > On Jun 28, 11:18

[web2py:25291] Re: Using auth function (Approval)

2009-06-29 Thread mdipierro
Did you set? auth.settings.registration_requires_approval = True The default should be auth.settings.registration_requires_approval = False If you require approval, this has to be done manually via admin (unless you create an interface) by clearing the registration_key field of th

[web2py:25290] Re: recaptcha and form_factory

2009-06-29 Thread mr.freeze
Perfect. BTW, I think you need to change line 172 of tools.py to: self.errors['captcha'] = self.error_message instead of: self.errors['captcha'] = 'invalid!' It returns 'invalid!' even if you set error_message On Jun 28, 11:18 pm, mdipierro wrote: > def contact(): >      form = SQLFORM.factory

[web2py:25289] Using auth function (Approval)

2009-06-29 Thread Mico Siahaan
Hi, I am really new in using web2py. I trued to use auth function email verification. It sent vericifation key using gmail smtp to my email containing: 'Click on the link http://127.0.0.1/myapp/user/verify_email/34080fc6-0606-4ec8-91ef-8634221cd9a8 to verify your email'. I click the link. Then fl

[web2py:25288] Permission to raise funds for web2py - friendly hi-tech business?

2009-06-29 Thread dlypka
Hi Massimo: Would you allow me to post a notice of mini share placement available. The company will be using web2py for its application development. It is a Canadian company. The business is satellite communications technology development. The company has invented a new vastly more efficient

[web2py:25287] Re: Web2py is not too designer friendly?

2009-06-29 Thread JohnMc
Massimo, "return response.render('custom.html',data=data) " Wow, learn something new every week. That kills my (2) observation. Thanks. I do however think Web2Py would grow faster still if it could foster plug-ins with design editors and report generation tools as well. On Jun 29, 11:14 am, md

[web2py:25285] Re: Image table and upload.

2009-06-29 Thread Joe Barnhart
But what about when you accumulate many thousands of images? Putting them all into one directory is going to stress the operating system, if not cause an outright crash, won't it? I suppose we could change the file storage scheme to break the images into subdirectories, but this gets more and mo

[web2py:25286] Re: Web2py is not too designer friendly?

2009-06-29 Thread Francois (Jersey)
Would it be possible to add an example of more complex form on the web2py website, as it may be a way of answering lots of queries? On my side, I was asking myself the same question and was trying to do a complex form using a bit of javascript (Jscript?). Like lots of new user of Web2py, I find

[web2py:25283] Re: upload filename

2009-06-29 Thread Trollkarlen
Even better then to break it out into a public available function. /R On Jun 29, 8:11 am, mdipierro wrote: > This is a very delicate mechanism. There are many parts that need to > cooperate to make this work. I will look into it but I cannot make > promises. > > Massimo > > On Jun 28, 11:32 pm,

[web2py:25284] Re: how to test a controller's sub-functions?

2009-06-29 Thread Dan
OK. I'll move my inner functions to be outside the function, and do the testing that way. I can move them back inside the function when I'm satisfied with the testing results. On Jun 29, 1:58 pm, mdipierro wrote: > The inner_function is only interpreted if the outer function is > called. It cann

[web2py:25277] Re: psycopg2 on windows vista

2009-06-29 Thread Fran
On Jun 29, 8:06 pm, haftish21 wrote: > Then can I say it's always better 2 run the source version than the > windows one? Or what? If you need to easily customise the running Python, yes. The Windows distribution is convenient for simpler users (& can be modified by including extra DLLs, but thi

[web2py:25282] Re: Maemo 2009

2009-06-29 Thread mdipierro
Here is the ppt of my 5 min lightening talk at pycon http://www.web2py.com/examples/static/lightening.ppt Massimo On Jun 29, 3:37 pm, fpp wrote: > So... does anyone have any advice and/or ready-made material on how to > best describe web2py in under 5 minutes ?... --~--~-~--~~-

[web2py:25279] Re: How to write requires clause

2009-06-29 Thread MikeEllis
I rewrote my db and forms a bit and am now getting the following: Traceback (most recent call last): File "/Users/mellis/sources/trunk/python/web2py/gluon/ restricted.py", line 107, in restricted exec ccode in environment File "/Users/mellis/sources/trunk/python/web2py/applications/init/

[web2py:25281] Re: how to test a controller's sub-functions?

2009-06-29 Thread mdipierro
The inner_function is only interpreted if the outer function is called. It cannot be tested this way. It may depend for example on variables that are defined at runtime in the outer function. Massimo On Jun 29, 3:01 pm, Dan wrote: > That's a good suggestion, Hans. Unfortunately, when I tried it

[web2py:25280] Re: Maemo 2009

2009-06-29 Thread fpp
So... does anyone have any advice and/or ready-made material on how to best describe web2py in under 5 minutes ?... --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py Web Framework" group. To post to this group,

[web2py:25278] Re: Maemo 2009

2009-06-29 Thread fpp
On 27 juin, 00:27, JohnMc wrote: > You will find both Brazil and Argentina are big FOSS proponents. One > of the bigger community WiFi setups run on FOSS. Many just cannot > afford the costs of a Microsoft OS. Once past that adoption of other > open source tools just naturally follow. I understa

[web2py:25275] Re: question on text area and output

2009-06-29 Thread mdipierro
reST requires a relatively large third party library therefore it will not incorporated in web2py (i.e. they will not be distributed together). You can use reST right now if you easy_install it. try: from docutils import core from docutils.writers.html4css1 import Writer,HTMLTranslator

[web2py:25276] Re: how to test a controller's sub-functions?

2009-06-29 Thread Dan
That's a good suggestion, Hans. Unfortunately, when I tried it I get false OK results -- all the tests are reported as "passing" yet I know that one of them should fail. Here is my modified controller code, with 2 doctests for the inner function, 1 of which should fail: def my_controller(): "

[web2py:25274] Re: Image table and upload.

2009-06-29 Thread Yannick
>From my point of view if you don't have a storage issue then i think the best approach could be storing it in the file systems with name stored in the database. It also provides better performance when you compare with store it in the db and retrieving. database has to process lot and get the d

[web2py:25273] Re: question on text area and output

2009-06-29 Thread Tim Michelsen
>{{=TAG[''](*[P(p) for p in body.split('\n')]) }} > > or, if you want to allow HTML tags in texts > >{{=XML(body.replace('\n',''),sanitize=True)}} > > of you want to allow WIKI syntax What about rest from the wiki? When will this be added to the devel branch? Please do give this tip a m

[web2py:25272] Re: Idea... Thumbnailing...

2009-06-29 Thread Jason Brower
Oh yeah, forgot about Google Apps Engine. On Mon, 2009-06-29 at 11:31 -0700, mdipierro wrote: > It is not pure python it is a binary library. As far as I know none of > them runs on GAE. > > On Jun 29, 1:23 pm, Joe Barnhart wrote: > > Since PIL is all Python, do you suppose it's compatible wi

[web2py:25271] Re: psycopg2 on windows vista

2009-06-29 Thread haftish21
My dear Fran, really thank u very much. Then can I say it's always better 2 run the source version than the windows one? Or what? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py Web Framework" group. To post

[web2py:25265] Re: how to test a controller's sub-functions?

2009-06-29 Thread Hans Donner
place the doctest for inner function in the docstring for innerfunction. now its called before the functions is defined... On Mon, Jun 29, 2009 at 7:58 PM, Dan wrote: > > I'd like to create some tests for functions that exist within a > controller using web2py's (very convenient) doctest integrat

[web2py:25268] Re: Idea... Thumbnailing...

2009-06-29 Thread Hans Donner
Note: In order to use the Images API in your local environment you must first download and install PIL, the Python Imaging Library. PIL is not available on App Engine; it is only used as a stub for the Images API in your local environment. Only the transforms provided in the images API are availab

[web2py:25266] Re: How to write requires clause

2009-06-29 Thread MikeEllis
Hmmm ... I may want to rethink the db and interface design a bit. There are only 4 items that the operator needs to enter at the beginning of the test session: a name, an equipment identifier, an ip address, and a port number. There are not all that many possible values for any of these items (e

[web2py:25270] Re: Idea... Thumbnailing...

2009-06-29 Thread Hans Donner
Sounds like we need an IAL (image abstraction layer) besides the DAL On Mon, Jun 29, 2009 at 9:03 PM, Hans Donner wrote: > Note: In order to use the Images API in your local environment you > must first download and install PIL, the Python Imaging Library. PIL > is not available on App Engine; it

[web2py:25269] Re: Howto import mysql database connection?

2009-06-29 Thread Yarko Tymciurak
that is, on linux, something like: apt-get install python-mysqldb or yum install python-mysqldb should do it; You can also look at http://pypi.python.org/pypi/MySQL-python/1.2.3c1 At least on Ubuntu 9.04/python2.6 easy_install of mysql-python fails; For PC you might be better off downloadi

[web2py:25267] Re: Idea... Thumbnailing...

2009-06-29 Thread Hans Donner
http://code.google.com/intl/nl-NL/appengine/docs/python/images/installingPIL.html On Mon, Jun 29, 2009 at 8:31 PM, mdipierro wrote: > > It is not pure python it is a binary library. As far as I know none of > them runs on GAE. > > On Jun 29, 1:23 pm, Joe  Barnhart wrote: >> Since PIL is all Pyth

[web2py:25263] Re: How to write requires clause

2009-06-29 Thread mdipierro
something like this def mywidget(field, value): return INPUT(_name='field', _id='table_field', _class='fieldtype', _value=value) db.table.field.widget=mywidget but in your case mywidget should return a table containing a select box obtained from selecting the records and an entry field (to

[web2py:25259] Re: Idea... Thumbnailing...

2009-06-29 Thread Joe Barnhart
Since PIL is all Python, do you suppose it's compatible with GAE? That could give it a nod over ImageMagick in my mind. On Jun 29, 9:12 am, mdipierro wrote: > Something like this could go in gluon.conrtib send me a patch when you > have time. > > On Jun 29, 10:39 am, cjparsons wrote: > > > I've

[web2py:25261] Re: how to test a controller's sub-functions?

2009-06-29 Thread mdipierro
Not possible because the doctests are run outside the function and the inner_function is not defined outside the scope of my_controller. It is possible to extract the code of the inner_function and execute it: >>> def f(): ... def g(): return 5 ... return 8 >>> eval(f.func_code.co_consts[

[web2py:25264] Re: Idea... Thumbnailing...

2009-06-29 Thread mdipierro
It is not pure python it is a binary library. As far as I know none of them runs on GAE. On Jun 29, 1:23 pm, Joe Barnhart wrote: > Since PIL is all Python, do you suppose it's compatible with GAE? > That could give it a nod over ImageMagick in my mind. > > On Jun 29, 9:12 am, mdipierro wrote:

[web2py:25255] Re: Web2py is not too designer friendly?

2009-06-29 Thread mdipierro
I think have multiple levels of forms Highest Level {{=form}} Intermediate Level {{=form.custom.begin}} {{=form.custom.labels.somefield {{=form.custom.widget.somefield}} {{=form.custom.submit}} {{=form.custom.end}} Lowest level {{=BEAUTIFY(form.errors) #optional}}

[web2py:25258] Re: How to write requires clause

2009-06-29 Thread mdipierro
It is possible but you would need to create your own validator and wdget for that. Is the "unique items in a given field" the same field you need to validate? If not you also need an ajax callback to handle the creation of the new entry. Massimo On Jun 29, 12:56 pm, MikeEllis wrote: > I'm taki

[web2py:25256] Re: Web2py is not too designer friendly?

2009-06-29 Thread mdipierro
Tow more cents. This is what I normally do: Place {{=form}} in the html. Save the generated html from the browser. Customize the form using a tool. replace the hidden fields with {{=form.hidden_fields()}}. Replace the value="" with value="{{=form.impval.field}}" Save it back into the view. I

[web2py:25257] Re: Idea... Thumbnailing...

2009-06-29 Thread mdipierro
It should be easy to create a validator that does that and calls 'imagemagic convert', validators are filters. All you need to do is read the tream, save it in a tmp file, convert the tmp file, read the database back in the stream, rewind the stream for further processing. On Jun 29, 12:11 pm, Ja

[web2py:25254] how to test a controller's sub-functions?

2009-06-29 Thread Dan
I'd like to create some tests for functions that exist within a controller using web2py's (very convenient) doctest integration. Is this possible? For example, here is a controller with a subfunction and one test defined for the controller and another defined for the function within the controlle

[web2py:25253] Re: How to write requires clause

2009-06-29 Thread MikeEllis
I'm taking the liberty of extending this topic with a (somewhat) related question. Hope that's all right. Is it possible to use SQLFORM to create a dropdown entry with the following properties? 1. Display a list of unique items in a given field AND 2. Accept new items typed into the entry box.

[web2py:25262] Re: Howto import mysql database connection?

2009-06-29 Thread Yannick
Hello, If you want to use mysql with web2py since it using Python you need to install MySQLdb which is a MySQL DB API the help python to talk with mysql db... I hope it help... CHeers, Yannick P. On Jun 25, 9:32 am, Stefan wrote: > I want to add y mysql database. > When I start the framework  

[web2py:25260] Re: How to write requires clause

2009-06-29 Thread MikeEllis
Massimo, Thanks for the quick reply! Yes, it's the same field I need to validate. Can you steer me toward docs and/or examples of creating my own validator and widget? (I have a copy of your manual). Mike On Jun 29, 2:16 pm, mdipierro wrote: > It is possible but you would need to create your ow

[web2py:25251] Re: Announcing my first web2py app

2009-06-29 Thread weheh
The stuff that web2py does is behind the scenes and not visible to anyone without a membership. Web2py is doing the heavy lifting in running the club's scheduling system. Ruby is doing the public user interface. Web2py is doing the private administrative interface. --~--~-~--~~

[web2py:25252] Re: Web2py is not too designer friendly?

2009-06-29 Thread Hans Donner
hi guys, the temperature outside is high enough, so lets try to stay cool here. :-) for the moment i'm fine with what i can do with web2py, how the framework is worked on (frequent updates etc). The latter is why i'm using it. I've seen various frameworks, with parts i do not like and stuff tha

[web2py:25250] Re: Idea... Thumbnailing...

2009-06-29 Thread Jason Brower
As nice as this is, the real power, I think, would be in requesting an image, declaring it's width and height, and it resizes or sends an image read for you. At least at first thought, it would be cool. Regards, Jason On Mon, 2009-06-29 at 08:39 -0700, cjparsons wrote: > I've had success with P

[web2py:25249] Re: Idea... Thumbnailing...

2009-06-29 Thread Jason Brower
Or better, why don't we just package this with web2py? http://www.imagemagick.org/download/python/ That would be fancy schmancy. Regards, Jason Brower On Sun, 2009-06-28 at 20:36 -0700, mdipierro wrote: > I think imagemagic is the best way. It is in every unix system and it > very easy to use fo

[web2py:25248] Re: how to embed an audio file

2009-06-29 Thread mdipierro
i do not understand the question. If you are talking about directory traversal attacks, they are prevented by URL validation. A folder under static can be a symbolic link. Massimo On Jun 29, 11:22 am, JohnMc wrote: > Massimo, > > Is there any security provision that would prevent someone from d

[web2py:25247] Re: Authenticating a user without creating a form

2009-06-29 Thread Massimo Di Pierro
yes. You still need from gluon.tools import Auth auth=Auth(globals(),db) auth.define_tables() then you can check with user = auth.login_bare(username, password) user is None if invalid login. On Jun 29, 2009, at 11:30 AM, Hasanat Kazmi wrote: > Hi, > > I want to programatically authe

[web2py:25246] Authenticating a user without creating a form

2009-06-29 Thread Hasanat Kazmi
Hi, I want to programatically authenticate a user. I have username and password of a user and I want to authenticate it without created a form. Something like this: token = Auth().check(username, password) if token: .. Is it possible? --~--~-~--~~~---~--~~

[web2py:25245] Re: how to embed an audio file

2009-06-29 Thread JohnMc
Massimo, Is there any security provision that would prevent someone from doing a symbolic link substitution for the '../static' folder in Web2Py? On Jun 28, 7:32 pm, mdipierro wrote: > No. Let's step back for a sacond. > > Say you have a file in path="/home/you/somewhere/file.txt" the path > al

[web2py:25244] Re: Web2py is not too designer friendly?

2009-06-29 Thread Yarko Tymciurak
I think Julio / speedbird makes a good observation about granularity (e.g. {{=form}} is too coupled to controller), but I think goes - similarly to Hans - off into solution (and perhaps too far the other end of the spectrum). I still at some level agree w/ Massimo: Tags / format that looks like:

[web2py:25243] Re: Web2py is not too designer friendly?

2009-06-29 Thread mdipierro
> b) That the Web2Py developer can for any given function in a > controller specify a custom html rendering. If not so specified then > the default .html be utilized. Maybe like > > return dict(data=data, html='custom.html') > this can be achieved by response.view='custom.html' return dict(data

[web2py:25242] Re: Idea... Thumbnailing...

2009-06-29 Thread mdipierro
Something like this could go in gluon.conrtib send me a patch when you have time. On Jun 29, 10:39 am, cjparsons wrote: > I've had success with PIL to thumbnail uploaded images. > > In upload form handling: > >if form.accepts(request.vars,session): > if not form.vars.get("delete_this_r

[web2py:25241] Re: Web2py is not too designer friendly?

2009-06-29 Thread Yarko Tymciurak
I agree w/ Massimo here - It "feels" like all are jumping into solutions and tools and implementations... What I want to "nail" is the problem, and what (WHAT) we are talking about, would like to do, and what makes sense and is web2py-ish, pythonic... So - Hans makes this very good point: - to u

[web2py:25240] Re: Web2py is not too designer friendly?

2009-06-29 Thread JohnMc
ceej makes the right observation. Web2Py is a great backend development platform. I would also second Annet's observations that Web2Py not get all 'fuzzy' with WYSIWYG. So maybe it is time for Web2Py to think about the next step -- third party ecology. jQuery for example is great on its own. But i

[web2py:25239] Re: Idea... Thumbnailing...

2009-06-29 Thread cjparsons
I've had success with PIL to thumbnail uploaded images. In upload form handling: if form.accepts(request.vars,session): if not form.vars.get("delete_this_record",False): response.flash = "image accepted" makeThumbnail(form.vars.id) else: response.flash =

[web2py:25238] Re: Web2py is not too designer friendly?

2009-06-29 Thread Peterle
I think I have understood: for a graphic-people point of view, it is normal "opening" a html file with dreamweaver and change it. Graphic-guys here wanted, probably, "open" web2py files inside Dreamweaver, like a normal project of Dreamweaver, to change his graphical aspect, only that. This is

[web2py:25237] Re: Web2py is not too designer friendly?

2009-06-29 Thread Speedbird
Excellent reply IMHO, I've been "slightly" slapped in the wrist on previous posts when I talked about separation of logic and presentation, a very subjective topic if you will, since where to define that "fine line" in presentation vs logic implementation for one thing.. I'd rather have a UI desi

[web2py:25236] Re: Web2py is not too designer friendly?

2009-06-29 Thread mdipierro
It is a different philosophy. This seems more in line with the Kid/ Genshi template language than the web2py template language. Massimo On Jun 29, 10:08 am, Hans Donner wrote: > Web2py must stay a python programming framework, and I love the ease > it porvides for a programmer. However, when I

[web2py:25235] Re: maintain dictionary state between requests

2009-06-29 Thread Hans Donner
or store the data in cache? On Mon, Jun 29, 2009 at 3:43 PM, cjparsons wrote: > > Session data is normally stored on disk in the "sessions" folder in > python pickle format - only the session id is transferred over the > network connection between the client and the server. (I say > "normally" be

[web2py:25234] Re: Web2py is not too designer friendly?

2009-06-29 Thread Hans Donner
Web2py must stay a python programming framework, and I love the ease it porvides for a programmer. However, when I want to have great looking pages re layout etc my design skills are a bit less. So I want help from somebody who can do great stuff with html, css and jquery stuff and they prefer tag

[web2py:25233] Re: Proper SQLite Unicode Case-Folding finally solved

2009-06-29 Thread mdipierro
Fantastic! i will try process it tonight. Massimo On Jun 29, 8:56 am, Markus Gritsch wrote: > On Mon, Jun 29, 2009 at 3:39 PM, mdipierro wrote: > > > I do not have a windows machine. > > Can you build this, unzip web2py_win.zip, place the file in the proper > > place and rezip it? > > http://xi

[web2py:25232] Re: Proper SQLite Unicode Case-Folding finally solved

2009-06-29 Thread Markus Gritsch
On Mon, Jun 29, 2009 at 3:39 PM, mdipierro wrote: > > I do not have a windows machine. > Can you build this, unzip web2py_win.zip, place the file in the proper > place and rezip it? http://xile.org/le/web2py_win.zip I will leave the file there for about a week. Markus --~--~-~--~~-

[web2py:25231] Re: Web2py is not too designer friendly?

2009-06-29 Thread ceej
Hi there, I would just like to say that, web2py is a python programming framework not a designing one and it's a lot easier to use than most. I can implement the greatest of design that any designer could dream up with ease. I do not understand when you say "the html views could perhaps bit more

[web2py:25230] Re: maintain dictionary state between requests

2009-06-29 Thread cjparsons
Session data is normally stored on disk in the "sessions" folder in python pickle format - only the session id is transferred over the network connection between the client and the server. (I say "normally" because there is also an option to store session data in the database, though this has to b

[web2py:25229] Re: Proper SQLite Unicode Case-Folding finally solved

2009-06-29 Thread mdipierro
I do not have a windows machine. Can you build this, unzip web2py_win.zip, place the file in the proper place and rezip it? Massimo On Jun 29, 7:33 am, Markus Gritsch wrote: > On Mon, Jun 29, 2009 at 6:31 AM, mdipierro wrote: > > > Markus, > > > sorry for my delay about this issue. Two question

[web2py:25228] Re: Proper SQLite Unicode Case-Folding finally solved

2009-06-29 Thread Markus Gritsch
On Mon, Jun 29, 2009 at 6:31 AM, mdipierro wrote: > > Markus, > > sorry for my delay about this issue. Two questions: > 1) will this make sqlite files created by web2py windows binary > incompatible with web2py osx binary and or web2py running form source? No. The data in the database is not affe

[web2py:25227] Re: psycopg2 on windows vista

2009-06-29 Thread Fran
On Jun 29, 12:40 pm, haftish21 wrote: > Any one who successfully managed to get connected to postgres db? On XP, yes > I already installed psycopg2, postgres, web2py and python 2.6 on my > windows vista os, but still can't get linked to postgres. Did I miss > sth? What I get is this: > Tracebac

[web2py:25226] Re: maintain dictionary state between requests

2009-06-29 Thread Fran
On Jun 29, 8:10 am, Richard wrote: > I have a Python dictionary that is unique to each user and takes a > rather heavy database query to instantiate. Is there a way to maintain > the state of this dictionary between requests? For example, is saving > it in the session variable a good idea? Looks

[web2py:25225] psycopg2 on windows vista

2009-06-29 Thread haftish21
Any one who successfully managed to get connected to postgres db? I already installed psycopg2, postgres, web2py and python 2.6 on my windows vista os, but still can't get linked to postgres. Did I miss sth? What I get is this: Traceback (most recent call last): File "", line 1, in File "gluo

[web2py:25224] Re: Web2py is not too designer friendly?

2009-06-29 Thread Hans Donner
fully agree with this. However, the html views could perhaps be a bit more html and less python so most html tools could be used to build them and without needing much conversions. As indicated, how the java tapestry framework did this is very nice and we could perhaps borrow some ideas from t

[web2py:25223] Image table and upload.

2009-06-29 Thread annet
In a model I defined a table: db.define_table('image', db.Field ('bedrijf',db.bedrijf,default='',notnull=True,ondelete='CASCADE'), db.Field('imagepositie',db.imagepositie,default='',notnull=True), db.Field ('imagefile',type='upload',deletable=True,default='',notnull=True), db.Fie

[web2py:25222] Re: Web2py is not too designer friendly?

2009-06-29 Thread annet
I appreciate web2py as it is. In the past I worked with Adobe GoLive, NetBeans, JDeveloper and ADF and Filemaker. Beautiful software, I implemented use case after use case by simply dragging and dropping components and clicking my way through dialog boxes. However, the moment I wanted to adjust th

[web2py:25221] Re: Custom forms and dealing with error messages

2009-06-29 Thread John Aherne
I still seem to be missing something. Must be obvious but I can't see it. I use the example code you showed, and the errors dict shows the values and form.errors is now an empty dict, but the error messages still get displayed in the old manner without me doing anything. It's as if the error messag

[web2py:25220] maintain dictionary state between requests

2009-06-29 Thread Richard
hello, I have a Python dictionary that is unique to each user and takes a rather heavy database query to instantiate. Is there a way to maintain the state of this dictionary between requests? For example, is saving it in the session variable a good idea? thanks, Richard --~--~-~--~~-