[web2py] Re: it case you missed it...

2010-12-12 Thread ron_m
I have seen LGPL mostly for C libraries like gstreamer so it is possible for projects to link to them. JBOSS the RedHat JEE platform also states that although JBOSS is GPL there is no requirement for applications written to run on the app server be GPL unless they take a piece of the platform that

[web2py] Re: administrator controller

2010-12-12 Thread mdipierro
can you tell us more? What does it do? Massimo On Dec 13, 12:20 am, Christopher Steel wrote: > Here is the same one, I added a menu item. but I have not touched it > in a while > > http://code.google.com/p/uc-admin/ > > I would be interested in any updates etc. as well.. > > Chris

[web2py] Re: it case you missed it...

2010-12-12 Thread mdipierro
On Dec 13, 12:28 am, Anthony wrote: > On Sunday, December 12, 2010 11:46:38 PM UTC-5, mdipierro wrote: There > are three cases: > 1) you distribute your app open or closed source with web2py source > (allowed by GPL) > > Doesn't the GPL by itself actually prohibit distributing a closed > source we

[web2py] Re: it case you missed it...

2010-12-12 Thread Anthony
On Sunday, December 12, 2010 11:46:38 PM UTC-5, mdipierro wrote: There are three cases: 1) you distribute your app open or closed source with web2py source (allowed by GPL) Doesn't the GPL by itself actually prohibit distributing a closed source web2py app because of the linking issue? I thought t

[web2py] Re: administrator controller

2010-12-12 Thread Christopher Steel
Here is the same one, I added a menu item. but I have not touched it in a while http://code.google.com/p/uc-admin/ I would be interested in any updates etc. as well.. Chris

[web2py] Re: it case you missed it...

2010-12-12 Thread Christopher Steel
This is a very good point indeed and seems like a great opportunity to bring our game up to a higher level. It seems to me that if the scaffolding app (welcome) is copyright Massimo and owned by him and/or Web2py then he/web2py have the legal right to do with it what they will. If we feel like ma

Re: [web2py] Re: web2py entry on wikipedia needs to be updated

2010-12-12 Thread Bruno Rocha
I think we can replace T2,T3 info with 'plugin_wiki' info. I am trying to understand that wiki markup.. :P

[web2py] Re: web2py entry on wikipedia needs to be updated

2010-12-12 Thread cjrh
On Dec 13, 3:06 am, Lorin Rivers wrote: > I made a few updates, version, book editions. I also fixed a few typos, and clarified some text.

Re: [web2py] Re: extra non-persistent fields in forms

2010-12-12 Thread Bruno Rocha
Sorry, my fault, SQLFORM.factory generates forms based on tables, but this does not make the inserts automatically. if you want to use that to include extra fields in a form it is a good choice, but you'll need to implement the 'inserts' for the table. orm=SQLFORM

[web2py] Re: Error in decorator section of web2py book

2010-12-12 Thread cjrh
On Dec 12, 11:40 pm, Luther Goh Lu Feng wrote: > Hmm, I actually deployed an app that uses that method: > > https://github.com/elfgoh/mustardjuice/blob/master/web2py/application... > > @auth.requires_membership('admin') worked but not > @auth.requires_membership(admin) (Line 56, 61) Ok, great, th

[web2py] Re: it case you missed it...

2010-12-12 Thread mdipierro
hmmm... I will study the LGPL some more. On Dec 12, 11:07 pm, Branko Vukelic wrote: > On Mon, Dec 13, 2010 at 5:46 AM, mdipierro wrote: > > imported module are distributed with the compiled app (case 1). It is > > not linking if the py or pyc modules are not distributed together > > (case 2). In

Re: [web2py] Re: extra non-persistent fields in forms

2010-12-12 Thread Bruno Rocha
The is that SQLFORM.factory does not generate form based on db.tables, and SQLFORM does, if you need to generate tables based on db.table and include extra fields to this form, I guess the only options is by appending/inserting to elements to the form, or doing that at JavaScript. 2010/12/13 weheh

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Branko Vukelic
On Mon, Dec 13, 2010 at 5:46 AM, mdipierro wrote: > imported module are distributed with the compiled app (case 1). It is > not linking if the py or pyc modules are not distributed together > (case 2). In case 2 the GPL does not apply. Case 1 is not allowed by > the GPL and that is why have the co

[web2py] Re: extra non-persistent fields in forms

2010-12-12 Thread weheh
I prefer customizing forms using SQLFORM.factory instead of the form insert/append method. It's a matter of choice and coding style, but both will work.

Re: [web2py] Re: extra non-persistent fields in forms

2010-12-12 Thread Bruno Rocha
One more thing. using form.append() the new item will be appended at the end of the form. if you want this item to be inserted ina desired position: a.insert(1,INPUT(_name='itemname')) when '1' is the position on index starting at 0, in every form created by SQLFORM the item 0 is , and you can

[web2py] Re: it case you missed it...

2010-12-12 Thread mdipierro
One think to clarify is the meaning of linking. Normally (in compiled languages) when you link a library the compiled code of the library becomes part of the executable. In the case of Python and interpreted languages you have import, which is not the same as linking. It is equivalent to linking IF

Re: [web2py] Re: extra non-persistent fields in forms

2010-12-12 Thread Bruno Rocha
form = SQLFORM(db.table) myinput = INPUT(_type='text',_name='testing',_value='blablabla') form.append(myinput) Example in shell: >>> a = SQLFORM(db.category) >>> a >>> print a Name: >>> a.append(INPUT(_type='text',_name='testing')) >>> a >>> print a Name: >>> 2010/12/13 Carlos > Hi weheh,

[web2py] Re: extra non-persistent fields in forms

2010-12-12 Thread Carlos
Hi weheh, Yes, I've looked at virtual and computed fields, but I believe (not sure) they do not provide the behavior I require. I need a non-persistent field/widget (e.g. checkboxes) in a regular persistent SQLFORM, such that the flow after the submit will depend on these non-persistent values. F

Re: [web2py] Re: SEO Tips & How this can be applied in web2py apps?

2010-12-12 Thread Branko Vukelic
On Mon, Dec 13, 2010 at 4:29 AM, Michael McGinnis wrote: > Those are good ideas. Automatically appending the site name at the end > of each title might be helpful. Or copying the first paragraph as a > fall-back meta-description (not so sure about that one). Or inserting > dynamic keywords for eac

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Branko Vukelic
On Mon, Dec 13, 2010 at 4:53 AM, LightDot wrote: > and all), but I've never seen it or done it. Which is also the point of MIT. And exactly why massimo insists on GPL, which forbids this. > So if the end result is the same (one can freely produce open or closed > source applications, modules, et

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread LightDot
I simply said we had customers expressing concern about using GPLv2 web2py framework for the task of developing a closed source web2py application. It was never about making closed source versions of web2py itself. Anyway, I think this issue has been addressed with authority in massimo's posts and

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Branko Vukelic
On Mon, Dec 13, 2010 at 4:36 AM, Graham Dumpleton wrote: > As such, you can't rely on what you quote above. The only way is an > exception statement to the GPL and even then that would need to be very > carefully worded. In all this you really need a lawyer to look at the > situation and draft tha

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Graham Dumpleton
On Monday, December 13, 2010 1:39:57 PM UTC+11, Branko Vukelic wrote:Since someone mentioned linking, etc, here's an exceprt from the GNU FAQ: Q. Does prelinking a GPLed binary to various libraries on the system, to optimize its performance, count as modification? A. No. Prelinking is part of a co

[web2py] Re: extra non-persistent fields in forms

2010-12-12 Thread weheh
Have you looked at virtual fields and computed fields? On Dec 12, 6:54 pm, Carlos wrote: > Hi, > > Is it possible to define extra non-persistent fields in forms, either > by CRUD or SQLFORM?. > > Or is SQLFORM.factory the only option?. > > Thanks, > >    Carlos

[web2py] Re: anybody use the web2py IRC chat?

2010-12-12 Thread weheh
That's what I always tell my son.

[web2py] How to test for form submission vs. form creation [Closed]

2010-12-12 Thread weheh
OK, I think I'm taking the cake today for quantity of dumb questions. I figured this one out by looking at the request.env.request_method and request.ajax variables.

[web2py] Re: SEO Tips & How this can be applied in web2py apps?

2010-12-12 Thread Michael McGinnis
Those are good ideas. Automatically appending the site name at the end of each title might be helpful. Or copying the first paragraph as a fall-back meta-description (not so sure about that one). Or inserting dynamic keywords for each page into the meta keywords. But we also have to avoid duplicate

Re: [web2py] Re: anybody use the web2py IRC chat?

2010-12-12 Thread Branko Vukelic
Take a deep breath. :) On Sun, Dec 12, 2010 at 10:32 PM, weheh wrote: > Yah, this group is wonderfully fast. Occasionally I get desperate, > though ... ;-) > > On Dec 12, 9:18 am, Branko Vukelic wrote: >> On Sun, Dec 12, 2010 at 8:48 AM, weheh wrote: >> > Just curious. I don't use it, but I pro

Re: [web2py] Re: Test for null not in a form

2010-12-12 Thread Branko Vukelic
On Mon, Dec 13, 2010 at 1:51 AM, Lorin Rivers wrote: > As far as I can tell, the only place null is mentioned in the DAL page is in > the definition of tables. None means NULL in Python, though. -- Branko Vukelić bg.bra...@gmail.com stu...@brankovukelic.com Check out my blog: http://www.bran

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Branko Vukelic
This may also be relevant: Q. In what cases is the output of a GPL program covered by the GPL too? A. Only when the program copies part of itself into the output. -- Branko Vukelić bg.bra...@gmail.com stu...@brankovukelic.com Check out my blog: http://www.brankovukelic.com/ Check out my portf

[web2py] Re: newbie

2010-12-12 Thread weheh
I assume you've got something like: db.define_table('story',Field('text'), ...) db.define_table('storyline',Field('story_id',db.story,requires=IS_IN_DB(db,'story.id','% (text)s'), ...) Then you can query the db: rows=db(db.storyline.story_id==session.story_id).select(db.story.ALL,left=db.story.

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Branko Vukelic
Since someone mentioned linking, etc, here's an exceprt from the GNU FAQ: Q. Does prelinking a GPLed binary to various libraries on the system, to optimize its performance, count as modification? A. No. Prelinking is part of a compilation process; it doesn't introduce any license requirements abo

[web2py] newbie

2010-12-12 Thread Shel
Hello, I am trying to create a form that displays all the rows in a table where, for example, db.storyline.story_id = session.story_id, and I cannot for the life of me figure out how to do this. It seems like this should be very simple, but nothing I have tried works. I am not sure how to use a

[web2py] Re: getting the full path to uploaded files

2010-12-12 Thread weheh
The reason I use folder='uploads' in the get_path arg list is because I use this same routine to get files that have been stored in various places: uploads, static, static/data ... etc. On Dec 12, 8:41 pm, "G. Clifford Williams" wrote: > Awesome thanks. > > On Sun, Dec 12, 2010 at 10:25:25AM -080

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Branko Vukelic
http://www.imdb.com/title/tt0097742/ On Mon, Dec 13, 2010 at 2:01 AM, mdipierro wrote: > Yes. The GPL prevents users from make a CLOSED SOURCE better > derivative of the framework. That is exactly what this community wants > to protect against. That is something that can kill an open source > pro

Re: [web2py] Re: reserved words in databases

2010-12-12 Thread Thadeus Burgess
Correct, it just lets you know if you have a conflicting name (for example, if your developing on sqlite and deploying on postgres, each has different reserved words list). You will still need to modify any conflicting table/field names -- Thadeus On Sun, Dec 12, 2010 at 7:37 PM, Carlos wrot

Re: [web2py] Re: getting the full path to uploaded files

2010-12-12 Thread G. Clifford Williams
Awesome thanks. On Sun, Dec 12, 2010 at 10:25:25AM -0800, weheh spake: > If uploadseparate=True then you have to reconstruct the full path with > a routine like this: > > > def get_path(filename,folder='uploads'): > """Get full path to file stored in uploads""" > f=filename.split('.') > p

[web2py] Re: reserved words in databases

2010-12-12 Thread Carlos
Hi Thadeus, I'm not doing any checking with "check_reserved" (http://web2py.com/ book/default/chapter/06?search=reserved#Reserved-Keywords), if that's what you're asking. I really did not fully understand that section, does it only check whether the current table and field names are in conflict o

[web2py] Re: XML service

2010-12-12 Thread DenesL
The arguments to select should be the fields, not their names: db(db.cargroup).select(db.cargroup.descr, db.cargroup.seats,orderby=db.cargroup.descr).as_list() On Dec 10, 1:53 pm, villas wrote: > If I make a function with named fields,  e.g. > > def cargroup(): >     carlist = > db(db.cargroup

Re: [web2py] web2py entry on wikipedia needs to be updated

2010-12-12 Thread Lorin Rivers
I made a few updates, version, book editions. On Dec 12, 2010, at 18:23 , Bruno Rocha wrote: > web2py entry on wikipedia[0] seens to be a little outdated showing > deprecated information about web2py. > > [ Who uses.., latest version, applied stack, T2 T3(??), book editions, wiki, > bazzar(?)...

[web2py] Re: it case you missed it...

2010-12-12 Thread mdipierro
Yes. The GPL prevents users from make a CLOSED SOURCE better derivative of the framework. That is exactly what this community wants to protect against. That is something that can kill an open source project and the reason GPL was invented. This discussion has nothing to do with users who are not a

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread pbreit
>> But as you say, BSD/MIT are better for users. > He didn't say that. He said it prevents users from making a better derivative. My apologies to the community and Massimo for be-laboring the point but I think it's unfortunate that the license alone is discouraging use of the framework. I'm ve

Re: [web2py] Re: Test for null not in a form

2010-12-12 Thread Lorin Rivers
As far as I can tell, the only place null is mentioned in the DAL page is in the definition of tables. On Dec 12, 2010, at 17:35 , mdipierro wrote: > The book never says that None is "NULL"? > I will check. That would be a big omission. > > Massimo > > On Dec 12, 5:24 pm, Lorin Rivers wrote:

[web2py] web2py entry on wikipedia needs to be updated

2010-12-12 Thread Bruno Rocha
web2py entry on wikipedia[0] seens to be a little outdated showing deprecated information about web2py. [ Who uses.., latest version, applied stack, T2 T3(??), book editions, wiki, bazzar(?)...] I never created or edited wikipedia pages before, I need to learn a little about this markup to start

Re: [web2py] Re: reserved words in databases

2010-12-12 Thread Thadeus Burgess
Are you using the reserved_keywords check built into the DAL? -- Thadeus On Sun, Dec 12, 2010 at 2:50 PM, Carlos wrote: > Hi Massimo, > > Thanks for clarifying this. > > Carlos > > > On Dec 11, 7:41 pm, mdipierro wrote: > > No. Right now there may problems if you used a reserved keyword.

[web2py] extra non-persistent fields in forms

2010-12-12 Thread Carlos
Hi, Is it possible to define extra non-persistent fields in forms, either by CRUD or SQLFORM?. Or is SQLFORM.factory the only option?. Thanks, Carlos

[web2py] Re: single [edit] instead of [create] + [update]

2010-12-12 Thread Carlos
Massimo, Great - thanks for confirming this ! Carlos On Dec 12, 5:32 pm, mdipierro wrote: > I do this all the time > > def edit(): >    return dict(form=crud.update(db.mytable,request.args(0))) > > when called withhttp://...editis just creates and when with ..edit/ > it goes into update mo

[web2py] How to test for form creation vs. acceptance with CRUD-like functionality?

2010-12-12 Thread weheh
.

[web2py] How to test

2010-12-12 Thread weheh
I'm doing #controller db.auth_user.default_2.requires=IS_IN_SET(...list depends on db.auth_user.default_1 ...) form=auth.profile(next=URL(r=request,f='profile')) to let the user enter stuff in their user profile (defaults, etc.). Once the form is loaded, ajax keeps auth_user.default_2 in syn

[web2py] Re: Test for null not in a form

2010-12-12 Thread mdipierro
The book never says that None is "NULL"? I will check. That would be a big omission. Massimo On Dec 12, 5:24 pm, Lorin Rivers wrote: > No kidding. That should be called out in The Book. > > On Dec 12, 2010, at 17:14 , mdipierro wrote: > > > > > db(db.mytable.myfield!=None).select() > > > On Dec

[web2py] Re: administrator controller

2010-12-12 Thread Richard
yes I understand the code required, but was after existing solution with nice looking view

[web2py] Re: single [edit] instead of [create] + [update]

2010-12-12 Thread mdipierro
I do this all the time def edit(): return dict(form=crud.update(db.mytable,request.args(0))) when called with http://...edit is just creates and when with ..edit/ it goes into update mode. On Dec 12, 5:25 pm, Carlos wrote: > Hi, > > I'm implementing crud functions for my models, and I'm won

[web2py] single [edit] instead of [create] + [update]

2010-12-12 Thread Carlos
Hi, I'm implementing crud functions for my models, and I'm wondering if it's a good idea for each table to just have one single [edit] function instead of two separate [create] and [update] functions?. This way I will internally search for the arg (record to be edited), which if absent then it's

Re: [web2py] Re: Test for null not in a form

2010-12-12 Thread Lorin Rivers
No kidding. That should be called out in The Book. On Dec 12, 2010, at 17:14 , mdipierro wrote: > db(db.mytable.myfield!=None).select() > > On Dec 12, 5:02 pm, Lorin Rivers wrote: >> Sometimes in the app I'm working on the default values aren't set in a >> column (for reasons outside of my con

[web2py] error messages while editing in fullscreen mode

2010-12-12 Thread Carlos
Hi, I've noticed that error messages (e.g. syntax errors) are not displayed when editing in fullscreen mode. The invalid section is highlighted correctly but with no message (as occurs in regular mode). The worst case is when the error is "communications error" (which occurs when a timeout occur

[web2py] Socket for bidirectional messaging

2010-12-12 Thread gopiballava
Hi, I'm interested in adding bidirectional messaging via sockets to a web2py app that I am developing. Clients will do standard web2py database stuff, and they will also be able to do instant messaging with other clients What is the best way to implement this within web2py? A separate sever proce

[web2py] Re: Test for null not in a form

2010-12-12 Thread mdipierro
db(db.mytable.myfield!=None).select() On Dec 12, 5:02 pm, Lorin Rivers wrote: > Sometimes in the app I'm working on the default values aren't set in a column > (for reasons outside of my control). > > So, instead of using the default value as a filter, I need to also test for > null. > > How do

[web2py] Test for null not in a form

2010-12-12 Thread Lorin Rivers
Sometimes in the app I'm working on the default values aren't set in a column (for reasons outside of my control). So, instead of using the default value as a filter, I need to also test for null. How do I do that in the DAL? In other words, "select * from table where field is not NULL;" --

[web2py] manual login-form

2010-12-12 Thread pk
hi, i hope somebody of you can help me very fast. how can i set the form-ID for the form (loginform) if i post the code {{=loginform}} i get this code automaticly: E-Mail: Passwort:   Angemeldet bleiben Passwort vergessen?

[web2py] Re: it case you missed it...

2010-12-12 Thread mdipierro
Once I created web2py 1.0 I registered both copyright and trademark. I paid for them. All web2py contributors sign a contributors agreement which gives me permissions to use the code as I see fit (and they also retain full rights on the contributed code), independently on the GPL. This means I can

[web2py] Re: it case you missed it...

2010-12-12 Thread VP
While I don't necessarily advocate for changing web2py's license, I think it's important to clarify the issues surrounding the license so people are clear. The question is "can a web2py app be not GPL when the framework is GPL?". I don't think it's as clear cut as someone might suggest. At least

[web2py] Re: SQLTABLE with joined data, but without repeats?

2010-12-12 Thread Carlos
Hi Denes, This seems to do the trick - thanks!, Carlos On Dec 12, 3:37 pm, DenesL wrote: > Try this: > > def join(): >   rows = db(db.one.id==db.many.one).select(db.many.id, db.many.one, > db.many.xx, db.many.yy, db.many.zz, db.one.aa, db.one.bb, db.one.cc) >   tr=[] >   f_many='id one xx y

[web2py] tags and tag cloud

2010-12-12 Thread Carlos
Hi, This is not a question specific to web2py, but it's more a generic inquiry. How does 'tags' usually work in a regular website (e.g. for articles/ blogs)?. I mean: Should tags be managed (create/update/delete tags) only by the admin or also by end users?. Should tags be used (tagging specif

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Michele Comitini
2010/12/12 pbreit : > Fair enough. But I do hope you will re-evaluate at some point as I strongly > believe that a non-GPL license would make Web2py much, much better. > And I think it is worthwhile trying to gain users since usage is the oxygen > for something like a framework. Sorry I have to di

[web2py] Re: Error in decorator section of web2py book

2010-12-12 Thread Luther Goh Lu Feng
On Dec 12, 10:58 pm, cjrh wrote: > On Dec 11, 7:44 pm, Luther Goh Lu Feng wrote: > > > Line 8 of code snippet should be > > @auth.requires_membership('agents') > > not > > @auth.requires_membership(agents) > > Are you sure?   I haven't tried it out myself, but I note that in a > subsequent line

[web2py] Re: SQLTABLE with joined data, but without repeats?

2010-12-12 Thread DenesL
Try this: def join(): rows = db(db.one.id==db.many.one).select(db.many.id, db.many.one, db.many.xx, db.many.yy, db.many.zz, db.one.aa, db.one.bb, db.one.cc) tr=[] f_many='id one xx yy zz'.split() f_one='aa bb cc'.split() if len(rows)>0: r=rows[0] tr.append([r.many[x] for x in f_m

[web2py] Re: Tip of the day

2010-12-12 Thread Carlos
Hi, I am wondering how this solution (single form with linked tables) can be used for updates (in addition to creates)?. Thanks, Carlos On Dec 6, 4:32 am, DenesL wrote: > True, only restriction is no common field names. > I have added this to the book. > > On Dec 5, 11:05 pm, mdipierro wr

[web2py] Re: anybody use the web2py IRC chat?

2010-12-12 Thread weheh
Yah, this group is wonderfully fast. Occasionally I get desperate, though ... ;-) On Dec 12, 9:18 am, Branko Vukelic wrote: > On Sun, Dec 12, 2010 at 8:48 AM, weheh wrote: > > Just curious. I don't use it, but I probably would if I thought I > > could get a fast response from an expert. > > Don'

[web2py] Re: it case you missed it...

2010-12-12 Thread pbreit
Fair enough. But I do hope you will re-evaluate at some point as I strongly believe that a non-GPL license would make Web2py much, much better. And I think it is worthwhile trying to gain users since usage is the oxygen for something like a framework.

[web2py] Re: reserved words in databases

2010-12-12 Thread Carlos
Hi Massimo, Thanks for clarifying this. Carlos On Dec 11, 7:41 pm, mdipierro wrote: > No. Right now there may problems if you used a reserved keyword. > > On Dec 11, 6:57 pm, Carlos wrote: > > > > > > > > > Hi, > > > With respect to the following old thread: > > >http://groups.google.com/g

[web2py] Re: upload files in specific sub-folders

2010-12-12 Thread Carlos
I'll give it a try. Thanks GoldenTiger ! On Dec 11, 1:00 pm, GoldenTiger wrote: > did you try Field arguments? > > http://www.web2py.com/examples/static/epydoc/index.html > > uploadfolder=None > uploadseparate=False # upload to separate directories by uuid_keys >                             # fi

[web2py] Re: SQLTABLE with joined data, but without repeats?

2010-12-12 Thread Carlos
Hi rochacbruno, That's what I thought, I just wanted to confirm it. Thanks to all !, Carlos On Dec 12, 10:50 am, rochacbruno wrote: > Carlos, the only solution I see is using a virtual field, or removing repeats > in Java Scripts. > > Enviado via iPhone > > Em 12/12/2010, às 14:17, Carlos

[web2py] Re: Translate this SQL to DAL?

2010-12-12 Thread mdipierro
More verbosely: max_reqtime = db.arraydata_table.reqtime.max() rows=db(db.arraydata_table.rollupid==0).select(max_reqtime) print rows.first()(max_reqtime) On Dec 12, 2:27 pm, DenesL wrote: > rows=db(db.arraydata_table.rollupid==0).select(db.arraydata_table.reqtime.max()) > > On Dec 12, 2:40 pm,

[web2py] Re: Translate this SQL to DAL?

2010-12-12 Thread DenesL
rows=db(db.arraydata_table.rollupid==0).select(db.arraydata_table.reqtime.max()) On Dec 12, 2:40 pm, Lorin Rivers wrote: > THere are a few aspects of the DAL that I can't  quite get my head around. > For example, how would I do this? > > select max(reqtime) from arraydata_table where rollupid

Re: [web2py] Re: anybody use the web2py IRC chat?

2010-12-12 Thread Lorin Rivers
I wish IRC was a little more active... On Dec 12, 2010, at 8:30 , Luther Goh Lu Feng wrote: > I do. But there are only about 10 people in the channel each time and > many are afk. The mailing list is a better bet. > > On Dec 12, 10:18 pm, Branko Vukelic wrote: >> On Sun, Dec 12, 2010 at 8:48 AM

[web2py] Translate this SQL to DAL?

2010-12-12 Thread Lorin Rivers
THere are a few aspects of the DAL that I can't quite get my head around. For example, how would I do this? select max(reqtime) from arraydata_table where rollupid = 0 -- Lorin Rivers Mosasaur: Killer Technical Marketing 512/203.3198 (m)

[web2py] Re: help needed with db table indexing within SQLFORM.factory [Closed]

2010-12-12 Thread weheh
It works. I think I know what I was doing wrong. I tried SQLFORM.factory(db.mytable,record=rowid). I suppose it's a little confusing that factory uses the SQLrow object for record and SQLFORM uses the record id. I've read and re-read the documentation on both SQLFORM and SQLFORM.factory and this di

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Branko Vukelic
On Sun, Dec 12, 2010 at 7:21 PM, mdipierro wrote: > I think we should close this discussion. It is not going anywhere. > The license of web2py is not up for discussion. +1 -- Branko Vukelić bg.bra...@gmail.com stu...@brankovukelic.com Check out my blog: http://www.brankovukelic.com/ Check ou

[web2py] Re: SQLCustomType no longer importable

2010-12-12 Thread Fran
On Dec 12, 6:04 pm, Fran wrote: > On Dec 12, 5:55 pm, mdipierro wrote: > > Oops. fixed in trunk. It should work now. > Thanks, it does :) Spoke too soon - it doesn't let me generate new records as the uuids aren't being generated properly :/ Here is where we use SQLCustomType to define the uuid

[web2py] Re: help needed with db table indexing within SQLFORM.factory

2010-12-12 Thread weheh
Strange, I'm almost certain I tried form=SQLFORM.factory(db.mytable,record=db.mytable[row]) but couldn't get it to work. I shall try again. Thanks much, DenesL! On Dec 12, 9:10 am, DenesL wrote: > form=SQLFORM.factory(db.mytable, record=db.mytable[row]) > > but why not simply > form=SQLFORM(db.my

[web2py] Re: BUTTON helper

2010-12-12 Thread weheh
That's an interesting idea. I didn't think of that. On Dec 12, 10:23 am, DenesL wrote: > You can always set it in a model as > BUTTON=TAG.BUTTON > > and then use it in your controllers and views. > > On Dec 12, 2:55 am, weheh wrote: > > > To be more explicit, I think BUTTON is good for newbies -

[web2py] Re: getting the full path to uploaded files

2010-12-12 Thread weheh
If uploadseparate=True then you have to reconstruct the full path with a routine like this: def get_path(filename,folder='uploads'): """Get full path to file stored in uploads""" f=filename.split('.') path=os.path.join(request.folder,folder, '%s.%s'%(f[0],f[1]), '%c%c'%(f[2]

[web2py] Re: it case you missed it...

2010-12-12 Thread mdipierro
I think we should close this discussion. It is not going anywhere. The license of web2py is not up for discussion. I say (and said) that the GPL license applies to derivative work only. Applications built with web2py and distributed with web2py (compiled or not) are not derivative work therefore t

[web2py] getting the full path to uploaded files

2010-12-12 Thread G. Clifford Williams
Is ther a prescribed mechanism for getting the full path to uploaded files? I've got an onaccept function that contains: os.symlink(os.path.join(request.folder,'uploads', form.vars.file_newfilename), link_path) which worked until I'd changed the field to use

[web2py] Re: SQLCustomType no longer importable

2010-12-12 Thread Fran
On Dec 12, 5:55 pm, mdipierro wrote: > Oops. fixed in trunk. It should work now. Thanks, it does :) > Long term anyway, I never promised backward compatibility for > SQLCustomType. ok, will be good to get a heads-up when that changes & some idea of how to migrate off it...or just tweak the impl

[web2py] Re: it case you missed it...

2010-12-12 Thread pbreit
The evidence is overwhelmingly in the other direction both in terms of what users want and what other frameworks offer. I don't think that's disputable.

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Branko Vukelic
On Sun, Dec 12, 2010 at 6:39 PM, pbreit wrote: > But as you say, BSD/MIT are better for users. He didn't say that. -- Branko Vukelić bg.bra...@gmail.com stu...@brankovukelic.com Check out my blog: http://www.brankovukelic.com/ Check out my portfolio: http://www.flickr.com/photos/foxbunny/ Re

[web2py] Re: SQLCustomType no longer importable

2010-12-12 Thread mdipierro
Oops. fixed in trunk. It should work now. Long term anyway, I never promised backward compatibility for SQLCustomType. Massimo On Dec 12, 11:52 am, Fran wrote: > Traceback (most recent call last): >   File "C:\Bin\web2py\gluon\restricted.py", line 188, in restricted >     exec ccode in environme

[web2py] SQLCustomType no longer importable

2010-12-12 Thread Fran
Traceback (most recent call last): File "C:\Bin\web2py\gluon\restricted.py", line 188, in restricted exec ccode in environment File "C:/Bin/web2py/applications/eden/models/00_db.py", line 21, in from gluon.sql import SQLCustomType ImportError: cannot import name SQLCustomType Are we n

[web2py] login form with a popup

2010-12-12 Thread pk
hi together, have somebody of you an example app or a code to make the login form with a popup like javascript colorbox for example?? thanks peter

[web2py] Re: it case you missed it...

2010-12-12 Thread mdipierro
I disagree. In the case of web2py it makes no difference to users since the web2py license clearly states it does not apply to them. Users of the framework can release their code under any license they like. Massimo On Dec 12, 11:39 am, pbreit wrote: > I'm not sure you can make that generaliza

[web2py] Re: it case you missed it...

2010-12-12 Thread pbreit
I'm not sure you can make that generalization with frameworks. The solid, widely used ones are all BSD/MIT (Rails, Django, Cake, CodeIgniter, Pylons, Turbogears, Symfony, etc.). But as you say, BSD/MIT are better for users.

Re: [web2py] Re: SEO Tips & How this can be applied in web2py apps?

2010-12-12 Thread Bruno Rocha
OK, I like every comments about 301 redirect, and this is a good tip. But, I started this post with this subject in mind: I am thinking on how we can have some helpers, functions, directives or just > improvements in 'welcome' app to help us follow this SEO tips? So, how can we develop some hel

Re: [web2py] Re: Accessing filename from upload field in onvalidation call

2010-12-12 Thread G. Clifford Williams
Thanks Massimo, Mr. Freeze and Weheh. In the end I just used form.vars.file.file.read(15) to make sure it was a SQLite file to begine with. At first I'd neglected to followup with a form.vars.file.file.seek(0) to reset the read position in the file. It's pretty important to remember that piece

[web2py] Re: it case you missed it...

2010-12-12 Thread mdipierro
It prevents a group of individuals or a company to make a better closed source derivative, and screw the original project. In my experience, MIT/BSD projects tend to be smaller, fragmented and with a lot of incompatible forks when compared with GPL projects. Of course there are exceptions. Massim

Re: [web2py] Re: SQLTABLE with joined data, but without repeats?

2010-12-12 Thread rochacbruno
Carlos, the only solution I see is using a virtual field, or removing repeats in Java Scripts. Enviado via iPhone Em 12/12/2010, às 14:17, Carlos escreveu: > Hi Denes, > > That's clear to me, my question is not about getting the data (I got > it ok), but instead showing the data in an html ta

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread Branko Vukelic
On Sun, Dec 12, 2010 at 5:08 PM, pbreit wrote: > Are there any advantages of GPL (with respect to "frameworks")? It depends. -- Branko Vukelić bg.bra...@gmail.com stu...@brankovukelic.com Check out my blog: http://www.brankovukelic.com/ Check out my portfolio: http://www.flickr.com/photos/fox

[web2py] Re: SEO Tips & How this can be applied in web2py apps?

2010-12-12 Thread ma...@rockiger.com
+1 PageRank is dying and not what Google really uses. The www.web2py.com vs web2py.com is a non issue from a search engine perspective. You can tell Google Webmaster Tools that web2py.com == www.web2py.com.

[web2py] Re: SQLTABLE with joined data, but without repeats?

2010-12-12 Thread Carlos
Hi Denes, That's clear to me, my question is not about getting the data (I got it ok), but instead showing the data in an html table (SQLTABLE) with unique (no repeated) "one" data, as per my examples above. Maybe I'm not explaining clearly? - sorry :-) Thanks!, Carlos On Dec 12, 9:41 am,

Re: [web2py] Re: it case you missed it...

2010-12-12 Thread pbreit
The disadvantages of GPL are somewhat clear. Are there any advantages of GPL (with respect to "frameworks")?

  1   2   >