[web2py:32610] New slice on Setting up Paypal
Hello, I have posted a slice on Setting up Paypal with Web2py. You can find it here: http://www.web2pyslices.com/main/slices/take_slice/9 I will be posting a better formated document with some images to better understand it shortly. One thing though, this was tested and programmed about 4 months ago, since then, Paypal has changed some of its APIs it seems, and some of the message names may have changed or no longer be available. This should be pretty basic to detect though. Best regards, Benigno. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32611] Re: New slice on Setting up Paypal
Your timing is excellent. I was just about to implement this on a site. Very helpful. On Oct 10, 2:04 am, Benigno wrote: > Hello, > > I have posted a slice on Setting up Paypal with Web2py. You can > find it here: > > http://www.web2pyslices.com/main/slices/take_slice/9 > > I will be posting a better formated document with some images to > better understand it shortly. > > One thing though, this was tested and programmed about 4 months > ago, since then, Paypal has changed some of its APIs it seems, and > some of the message names may have changed or no longer be available. > This should be pretty basic to detect though. > > Best regards, > Benigno. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32612] why doesn't this ajax call work?
This doesn't work: --- # default controller def play(): return dict() def echo(): import random return "jQuery('#target').html('%s');" % DIV(random.randint(1,100)) # default view {{extend 'layout.html'}} this is a test {{=A(T('TEST'),_href='#',_class='title',_onclick="ajax('echo', ['name'],':eval')")}} - But if I change the default view to the following, both links work when I click on them: # default view {{extend 'layout.html'}} this is a test test {{=A(T('TEST'),_href='#',_class='title', _onclick="ajax('echo',['name'],':eval')")} Also, this works, too, when I have just the link and no helper. # default view {{extend 'layout.html'}} this is a test test --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32613] strip whitespace before validating fields
(re-posting since I think my previous message went to just one person) Is there an option or a validator that will strip whitespace before applying remaining validators for a given field on a form? Somewhat related: I tried the CLEANUP validator but the resulting variable still had characters like !...@#%^ in it. Maybe I mis-understood its purpose... perhaps it strips special characters for the other validators, but then when everything is done the original typed value gets sent? It would be cool if there were a validator that took a regex or a list of characters and stripped those from the input (so a phone field might ignore everything except digits). I checked the documentation and for some reason the source code has strike-out markup over it. http://mdp.cti.depaul.edu/examples/static/epydoc/web2py.gluon.validators-pysrc.html#CLEANUP.__call__ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32614] Re: newbie: returning Controller variable to View
On Oct 9, 9:40 pm, ed wrote: > Hi Massimo, > Your suggestion is very neat and beyond my limited web2py knowledge: > > Mind that you do not need anything like this if your purpose is login. > In that case web2py already provides method for login and the user > info is simply in > {{=auth.user.first_name}} {{=auth.user.last_name}} > -- > I tried the above code in the View Hi, {{=auth.user.first_name}} p> unfortunately got an error; > AttributeError: 'NoneType' object has no attribute 'first_name' That is because you are not logged in. try: Hi, {{if auth.user:}}{{=auth.user.first_name}}{{else:}}anonymous {{pass}}< /p> > --- > I searched and found this at Mark Mail: > auth.user.id -- this is the global variable 'auth' which has a > variable named 'user' which in turn has a named variable called > 'id'. This variable is valid only after a user is logged on and it > refers to the id of the current user. If no one is logged in, > auth.user does not exist and has the value of 'None'. But None has no > named variable 'id' so you get an error if you try to use it. Same problem as before. if not logged in auth.user is None. > -- > So, definitely with the following Controller code i was not able to > logged in since my View encountered an "Attribute error: Nonetype > object has no attribute 'first_name' " and failed to display > {{=auth.user.first_name}}? The following is the actual code: > Controller: > def user: > if request.args(0)=='login': > form = SQLFORM.factory( > Field('emailad', 'emailad',requires=[IS_LENGTH > (maxsize=30,error_message='Maximum length 30 chars..'),IS_EMAIL(), > IS_IN_DB(db,'auth_user.email',error_message='Email address does not > exist.')], required=True, label='Email Address'), > Field('password', 'password', requires=[IS_IN_DB > (db,'auth_user.password',error_message='Password is not the > same.')],label='Password')) > form[0][-1][1].append(INPUT > (_type='button',_value='Cancel',_onclick="window.location='%s';"%URL > (r=request,f='index'))) > > if form.accepts(request.vars, session): > em=request.vars.emailad > session.flash = 'You are now logged in %s .' % > name > redirect(URL(r=request,f='loggedin')) > return dict(form=form) > View: > {{extend 'layout2.html'}} > > Hi {{=auth.user.first_name}} > > . > Massimo, i tried to adopt your code but an error was encountered > during the run. What shall i do to adopt your code which is very > simple? Thank you again for your patience and very prompt responses. > > On Oct 9, 8:59 pm, mdipierro wrote: > > > Something like this? > > > def page1(): > > form=SQLFORM.factory(Field('email',requires=IS_IN_DB > > (db,'auth_user.email'))) > > if form.accepts(request.vars, session): > > redirect(URL(r=request,f='page2',dict(em=form.vars.email)) > > return dict(form=form) > > > {{extend 'layout.html'}}{{=form}} > > > def page2(): > > rows=db(db.auth_user.email==request.vars.em).select() > > if not rows: redirect(URL(r=request,f='page1')) > > return dict(name=rows.first().first_name) > > > {{extend 'layout.html'}}Hello {{=name}} > > > Mind that you do not need anything like this if your purpose is login. > > In that case web2py already provides method for login and the user > > info is simply in > > {{=auth.user.first_name}} {{=auth.user.last_name}} > > > On Oct 9, 1:34 am, ed wrote: > > > > Hi Massimo, > > > Okay, redirect returns page but without any variable. Any hint how to > > > render a page name "loggedin" that says; "Hi Ed, welcome!" after a > > > succesful login using the code i created?. Sorry, i'm a newbie with > > > very limited web2py knowledge and stucked on this. Thank you in > > > advance Massimo. > > > > On Oct 9, 11:58 am, mdipierro wrote: > > > > > mind that redirect is a function that raises an HTTP exception which > > > > causes the server to send and HTTP 303 response. redirect never > > > > returns and your view is never rendered. > > > > > Massimo > > > > > On Oct 8, 9:22 pm, ed wrote: > > > > > > The display went well because i filled a session with a constant "Ed" > > > > > and not a result of a db().select(). So, the constant variable was > > > > > displayed without a hitch. When i used db().select() the display went > > > > > like: > > > > > [{'first_name': 'Ed'}] > > > > > The above display is the result of the following code: > > > > > Controller: > > > > > if form.accepts(request.vars, session): > > > > > em=request.vars.emailad > > > > > name1 = db(db.auth_user.email==em).select(db.auth_user.first_name) > > > > > [0] > > > > > name=name1.first_name >
[web2py:32615] Re: New slice on Setting up Paypal
+1 On Oct 10, 2:04 am, Benigno wrote: > Hello, > > I have posted a slice on Setting up Paypal with Web2py. You can > find it here: > > http://www.web2pyslices.com/main/slices/take_slice/9 > > I will be posting a better formated document with some images to > better understand it shortly. > > One thing though, this was tested and programmed about 4 months > ago, since then, Paypal has changed some of its APIs it seems, and > some of the message names may have changed or no longer be available. > This should be pretty basic to detect though. > > Best regards, > Benigno. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32616] Re: strip whitespace before validating fields
I agree. Sometimes I think stripping should be a default for non-text, non-blob fields. Pros/cons? On Oct 10, 7:52 am, devnull wrote: > (re-posting since I think my previous message went to just one person) > > Is there an option or a validator that will strip whitespace before > applying remaining validators for a given field on a form? > > Somewhat related: I tried the CLEANUP validator but the resulting > variable still had characters like !...@#%^ in it. Maybe I mis-understood > its purpose... perhaps it strips special characters for the other > validators, but then when everything is done the original typed value > gets sent? It would be cool if there were a validator that took a > regex or a list of characters and stripped those from the input (so a > phone field might ignore everything except digits). > > I checked the documentation and for some reason the source code has > strike-out markup over > it.http://mdp.cti.depaul.edu/examples/static/epydoc/web2py.gluon.validat... --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32617] Re: why doesn't this ajax call work?
When the ajax call is embedded in the helper, Firebug complains: document.getElementById(s[i]) is null [Break on this error] query=query+encodeURIComponent(s[i]...t (document.getElementById(s[i]).value);\n --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32618] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
Perfect ! Massimo. -- Leandro --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32620] Re: why doesn't this ajax call work?
I tried the ajax call from within an XML() helper and it also failed. So, it would appear that the helpers aren't being so helpful when it comes to ajax calls. :-( --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32619] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
I really appreciate when people report solved problem and change the thread title as you did. :-) Thank you Leandro. On Oct 10, 10:32 am, ProfessionalIT wrote: > Perfect ! Massimo. > > -- Leandro --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32621] Re: why doesn't this ajax call work?
Because the link in the first view doesn't have an id attribute. Try this: {{=A(T('TEST'),_id="name",_href='#',_class='title',_onclick="ajax ('echo',['name'],':eval');")}} On Oct 10, 2:55 am, weheh wrote: > This doesn't work: > --- > # default controller > def play(): > return dict() > def echo(): > import random > return "jQuery('#target').html('%s');" % DIV(random.randint(1,100)) > > # default view > {{extend 'layout.html'}} > this is a test > {{=A(T('TEST'),_href='#',_class='title',_onclick="ajax('echo', > ['name'],':eval')")}} > - > But if I change the default view to the following, both links work > when I click on them: > > # default view > {{extend 'layout.html'}} > this is a test > onclick="ajax('echo',['name'],':eval')" >test > {{=A(T('TEST'),_href='#',_class='title', > _onclick="ajax('echo',['name'],':eval')")} > > Also, this works, too, when I have just the link > and no helper. > > # default view > {{extend 'layout.html'}} > this is a test > onclick="ajax('echo',['name'],':eval')" >test --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32622] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
This should be an standard on this group to facilitate the search of common solved issues! +1 Alex F El 10/10/2009 17:39, mdipierro escribió: > I really appreciate when people report solved problem and change the > thread title as you did. :-) > Thank you Leandro. > > On Oct 10, 10:32 am, ProfessionalIT wrote: > >> Perfect ! Massimo. >> >> -- Leandro >> > > > > -- Alejandro Fanjul Fdez. alex.fan...@gmail.com www.mhproject.org --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32623] hg and google
http://googlecode.blogspot.com/2009/10/mercurial-server-side-clone-support-for.html --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32624] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
except that only "small" problem is that i even don't know for what that thread was about :) I'm receiving emails trough gmail and it can't follow thread this way definitely... On Sat, Oct 10, 2009 at 5:39 PM, mdipierro wrote: > > I really appreciate when people report solved problem and change the > thread title as you did. :-) > Thank you Leandro. > > On Oct 10, 10:32 am, ProfessionalIT wrote: >> Perfect ! Massimo. >> >> -- Leandro > > > -- "Only two things are infinite, the universe and human stupidity, and I'm not sure about the former."-Albert Einstein --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32625] Re: why doesn't this ajax call work? [RESOLVED - Pilot error]
Yes, indeed, you are right. I'm wondering why I overlooked such an obvious thing since I knew about that requirement. Anyway, thanks for being an extra pair of smart eyeballs. On Oct 10, 11:51 am, "mr.freeze" wrote: > Because the link in the first view doesn't have an id attribute. Try > this: > > {{=A(T('TEST'),_id="name",_href='#',_class='title',_onclick="ajax > ('echo',['name'],':eval');")}} > > On Oct 10, 2:55 am, weheh wrote: > > > > > This doesn't work: > > --- > > # default controller > > def play(): > > return dict() > > def echo(): > > import random > > return "jQuery('#target').html('%s');" % DIV(random.randint(1,100)) > > > # default view > > {{extend 'layout.html'}} > > this is a test > > {{=A(T('TEST'),_href='#',_class='title',_onclick="ajax('echo', > > ['name'],':eval')")}} > > - > > But if I change the default view to the following, both links work > > when I click on them: > > > # default view > > {{extend 'layout.html'}} > > this is a test > > > onclick="ajax('echo',['name'],':eval')" >test > > {{=A(T('TEST'),_href='#',_class='title', > > _onclick="ajax('echo',['name'],':eval')")} > > > Also, this works, too, when I have just the link > > and no helper. > > > # default view > > {{extend 'layout.html'}} > > this is a test > > > onclick="ajax('echo',['name'],':eval')" >test- Hide quoted text - > > - Show quoted text - --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32626] Newbie Question: Using SQLFORM with my own HTML
Hi I have a controller function: def settings(): form = SQLFORM(db.settings) if form.accepts(request.vars,session): response.flash = 'form submitted' elif form.errors: response.flash = 'form has errors' else: response.flash = 'please fill out the form' return dict() and a view: {{extend 'layout.html'}} Settings Title: but whenever I display the form and hit submit, I only ever get 'please fill in form' - am I doing something really stupid. thanks Portly --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32627] Re: strip whitespace before validating fields
I agree too. On Oct 10, 10:02 am, mdipierro wrote: > I agree. Sometimes I think stripping should be a default for non-text, > non-blob fields. Pros/cons? > > On Oct 10, 7:52 am, devnull wrote: > > > (re-posting since I think my previous message went to just one person) > > > Is there an option or a validator that will strip whitespace before > > applying remaining validators for a given field on a form? > > > Somewhat related: I tried the CLEANUP validator but the resulting > > variable still had characters like !...@#%^ in it. Maybe I mis-understood > > its purpose... perhaps it strips special characters for the other > > validators, but then when everything is done the original typed value > > gets sent? It would be cool if there were a validator that took a > > regex or a list of characters and stripped those from the input (so a > > phone field might ignore everything except digits). > > > I checked the documentation and for some reason the source code has > > strike-out markup over > > it.http://mdp.cti.depaul.edu/examples/static/epydoc/web2py.gluon.validat... --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32628] Re: why doesn't this ajax call work? [RESOLVED - Pilot error]
No problem. Sometimes the longer I stare at a problem, the less I see :) On Oct 10, 11:37 am, weheh wrote: > Yes, indeed, you are right. I'm wondering why I overlooked such an > obvious thing since I knew about that requirement. Anyway, thanks for > being an extra pair of smart eyeballs. > > On Oct 10, 11:51 am, "mr.freeze" wrote: > > > Because the link in the first view doesn't have an id attribute. Try > > this: > > > {{=A(T('TEST'),_id="name",_href='#',_class='title',_onclick="ajax > > ('echo',['name'],':eval');")}} > > > On Oct 10, 2:55 am, weheh wrote: > > > > This doesn't work: > > > --- > > > # default controller > > > def play(): > > > return dict() > > > def echo(): > > > import random > > > return "jQuery('#target').html('%s');" % DIV(random.randint(1,100)) > > > > # default view > > > {{extend 'layout.html'}} > > > this is a test > > > {{=A(T('TEST'),_href='#',_class='title',_onclick="ajax('echo', > > > ['name'],':eval')")}} > > > - > > > But if I change the default view to the following, both links work > > > when I click on them: > > > > # default view > > > {{extend 'layout.html'}} > > > this is a test > > > > > onclick="ajax('echo',['name'],':eval')" >test > > > {{=A(T('TEST'),_href='#',_class='title', > > > _onclick="ajax('echo',['name'],':eval')")} > > > > Also, this works, too, when I have just the link > > > and no helper. > > > > # default view > > > {{extend 'layout.html'}} > > > this is a test > > > > > onclick="ajax('echo',['name'],':eval')" >test- Hide quoted text - > > > - Show quoted text - --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32629] Re: Newbie Question: Using SQLFORM with my own HTML
You can use form.custom: {{=form.custom.begin}} Title: {{=form.custom.widget.title}} {{=form.custom.end}} Or if you don't want to use the widgets serialized by web2py, you can replace them with html but you must follow the naming convention. I would read on page 235 (labeled 219) of the manual for more info: http://web2py.com/examples/default/docs On Oct 10, 11:51 am, "portly.shor...@googlemail.com" wrote: > Hi I have a controller function: > > def settings(): > > form = SQLFORM(db.settings) > > if form.accepts(request.vars,session): > response.flash = 'form submitted' > elif form.errors: > response.flash = 'form has errors' > else: > response.flash = 'please fill out the form' > return dict() > > and a view: > > {{extend 'layout.html'}} > Settings > > Title: > > > > > > but whenever I display the form and hit submit, I only ever get > 'please fill in form' - am I doing something really stupid. > > thanks > > Portly --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32630] Re: Newbie Question: Using SQLFORM with my own HTML
Perfect. Many thanks. Really must read the FULL manual :-). cheers Portly On Oct 10, 7:14 pm, "mr.freeze" wrote: > You can use form.custom: > > {{=form.custom.begin}} > Title: {{=form.custom.widget.title}} > {{=form.custom.end}} > > Or if you don't want to use the widgets serialized by web2py, you can > replace them with html but you must follow the naming convention. I > would read on page 235 (labeled 219) of the manual for more > info:http://web2py.com/examples/default/docs > > On Oct 10, 11:51 am, "portly.shor...@googlemail.com" > > > > wrote: > > Hi I have a controller function: > > > def settings(): > > > form = SQLFORM(db.settings) > > > if form.accepts(request.vars,session): > > response.flash = 'form submitted' > > elif form.errors: > > response.flash = 'form has errors' > > else: > > response.flash = 'please fill out the form' > > return dict() > > > and a view: > > > {{extend 'layout.html'}} > > Settings > > > > Title: > > > > > > > > > but whenever I display the form and hit submit, I only ever get > > 'please fill in form' - am I doing something really stupid. > > > thanks > > > Portly --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32631] Re: gluon.contrib.login_methods gae_google_account.py
In other words, it is a bug. On Oct 6, 4:37 pm, "mr.freeze" wrote: > Is the ChunkedReader class supposed to be there? It seems to be > missing some stuff. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32632] Re: Try out admin editor
Hey! Who-ya callin' ol' ? ;-) On Fri, Oct 9, 2009 at 11:08 PM, weheh wrote: > > You don't have to be old like Yarko and me to remember ^S ^Q. Just > open a DOS window and do a dir /s from the c: drive. Then trip down > memory lane as you exercise your left hand's 3rd, 4th and 5th fingers. > > On Oct 9, 10:33 pm, Yarko Tymciurak wrote: > > On Fri, Oct 9, 2009 at 9:01 PM, Iceberg wrote: > > > > > You are right, Yarko. And perhaps that is exactly why we can not > > > expect much from those editors-inside-a-browser-window. Let it be. :-) > > > > hehehe yes, and I have some ancient, reptilian memory of CTRL-S > > being used to "stop" output at the terminal (and I think it used to send > a > > NACK down the 300 baud lines; back in those days - which were SO much > nicer > > than punched cards and printouts - at 300 baud, or about 30 characters > per > > second yes, 2-3 seconds per LINE of output on your terminal!!! > > > you simply did NOT need paging programs much, and interactive editors had > to > > be EXTREMELY efficient in output, or no one would use them! > > > > Ah,,, Good old CTRL-S / CTRL-Q for STOP and RERUME output; > > _those were the days! > > > > NOT! :-) > > > > > > > > > On Oct10, 2:55am, Yarko Tymciurak wrote: > > > > CTRL-S is too old, and too widely used; it's "save" from probably > every > > > > browser in every environment in existence > > > > > > In ASCII, it is "Device Control 3", and has been used for terminal > > > control > > > > since the beginnings of the use of terminals. > > > > > > On Fri, Oct 9, 2009 at 3:52 AM, Iceberg wrote: > > > > > > > Do you mean that the ctrl+s is already implemented in current > web2py > > > > > latest trunk? > > > > > > > But I tried in IE7, ctrl+s doesn't invoke any action. And I tried > in > > > > > Chrome3, ctrl+s just invoke the browser's built-in "save current > page > > > > > to local harddisk" feature. > > > > > > > Well, not a big deal. I am just curious to know whether ctrl+s > works > > > > > in other user's environment. If it does not work, I won't mind > because > > > > > it is not really my first choice to edit my app. :-) > > > > > > > On Oct7, 10:10pm, mdipierro wrote: > > > > > > Please check again it should be there > > > > > > > > On Oct 7, 4:26 am, Iceberg wrote: > > > > > > > > > Looks like the problem is already addressed 3 weeks ago. But I > did > > > not > > > > > > > find a file named keyboard.js in our web2py admin. > > > > > > > > http://sourceforge.net/projects/editarea/forums/forum/556921/topic/33. > > > .. > > > > > > > > > On Oct7, 11:24am, mdipierro wrote: > > > > > > > > > > Can you send me a patch? > > > > > > > > > > On Oct 6, 7:30 am, Kuba Kucharski > > > wrote: > > > > > > > > > > > Still the main problem with admin editor is this > > > > > > > > > wrong-refreshing/wrong-displaying trauma - never solved or > did > > > I > > > > > miss smth ? > > > > > > > > > > > On Oct 5, 2009 3:47 AM, "Iceberg" > wrote: > > > > > > > > > > > Did not really try the admin editor until recently. Nice as > a > > > handy > > > > > > > > > tool for some quick typing, the only inconvenience is the > lack > > > of > > > > > ctrl > > > > > > > > > +s shortcut to save a file. Is it possible to add this > feature? > > > > > Since > > > > > > > > > I notice the ctrl+f etc can work. > > > > > > > > > > > BTW, the word_wrap.gif icon is missing in the toolbar. > > > > > > > > > > > Regards, > > > > > > > > > Iceberg- Hide quoted text - > > > > - Show quoted text - > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32633] Re: gluon.contrib.login_methods gae_google_account.py
oops. cut and paste problem. removed On Oct 10, 1:29 pm, "mr.freeze" wrote: > In other words, it is a bug. > > On Oct 6, 4:37 pm, "mr.freeze" wrote: > > > Is the ChunkedReader class supposed to be there? It seems to be > > missing some stuff. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32634] SELECT - UTF-8 errors
I have same string inserted in a table. When I select them, I debug this error: File "/xx/xx/web2py/web2py/gluon/sql.py", line 2235, in response return self._db._cursor.fetchall() OperationalError: Could not decode to UTF-8 column 'subject' with text 'x � i�xxx' This is a problem of sql.py module. What can I do? Thanks --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32635] Re: A simple patch to provide upload progress
@AndCycle I rearranged the code in trunk a bit. Could you check it still works? Thanks again. Massimo On Oct 8, 5:14 am, AndCycle wrote: > thanks :) > > I will take some free time to write a example base on trunk :p > > On Oct 7, 10:24 pm, mdipierro wrote: > > > Check again. I added it now. > > > On Oct 7, 6:42 am, AndCycle wrote: > > > > oops, the patch been cut by width restriction on mailing list lol > > > > here is pastebinhttp://pastebin.com/f219d603b --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32636] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
Agreed, I do all communication through gmail, no way to change topic or follow topics, no clue what he was talking about :P -Thadeus On Sat, Oct 10, 2009 at 11:22 AM, Boris Manojlovic < boris.manojlo...@gmail.com> wrote: > > except that only "small" problem is that i even don't know for what > that thread was about :) > > I'm receiving emails trough gmail and it can't follow thread this way > definitely... > > > On Sat, Oct 10, 2009 at 5:39 PM, mdipierro > wrote: > > > > I really appreciate when people report solved problem and change the > > thread title as you did. :-) > > Thank you Leandro. > > > > On Oct 10, 10:32 am, ProfessionalIT wrote: > >> Perfect ! Massimo. > >> > >> -- Leandro > > > > > > > > > -- > "Only two things are infinite, the universe and human stupidity, and > I'm not sure about the former."-Albert Einstein > > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32637] Re: strip whitespace before validating fields
> I agree. Sometimes I think stripping should be a default for non-text, > non-blob fields. Pros/cons? Breaks backwards compatability. So under our banner of web2pyism, we can't do it. However, devnull, try this, this will alter the input before you validate it through the form, so you can apply operators, such as stripping, or .capitalize() or .upper() or anything really :P def decode(string, strip="!...@#$%^&*()"): newstr = "" for char in string: if char not in strip: newstr += char return newstr def myaction(): if request.vars: request.vars.fieldname = decode(request.vars.fieldname) form = SQLFORM(db.tablename) if form.accepts(request.vars, session): response.flash = "yay" elif form.errors: response.flash = "nay" else: response.flash = "hey" -Thadeus On Sat, Oct 10, 2009 at 1:02 PM, JorgeR wrote: > > I agree too. > > On Oct 10, 10:02 am, mdipierro wrote: > > I agree. Sometimes I think stripping should be a default for non-text, > > non-blob fields. Pros/cons? > > > > On Oct 10, 7:52 am, devnull wrote: > > > > > (re-posting since I think my previous message went to just one person) > > > > > Is there an option or a validator that will strip whitespace before > > > applying remaining validators for a given field on a form? > > > > > Somewhat related: I tried the CLEANUP validator but the resulting > > > variable still had characters like !...@#%^ in it. Maybe I mis-understood > > > its purpose... perhaps it strips special characters for the other > > > validators, but then when everything is done the original typed value > > > gets sent? It would be cool if there were a validator that took a > > > regex or a list of characters and stripped those from the input (so a > > > phone field might ignore everything except digits). > > > > > I checked the documentation and for some reason the source code has > > > strike-out markup over it. > http://mdp.cti.depaul.edu/examples/static/epydoc/web2py.gluon.validat... > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32638] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
When you post about an issue and the issue is solved and you email a response saying the issue is solved make sure you edit the subject and append [SOLVED]. That is all. Most people, including me, do not use email for posting/reading. We access the groups.google.com/group/web2py page directly. Massimo On Oct 10, 3:13 pm, Thadeus Burgess wrote: > Agreed, I do all communication through gmail, no way to change topic or > follow topics, no clue what he was talking about :P > > -Thadeus > > On Sat, Oct 10, 2009 at 11:22 AM, Boris Manojlovic < > > boris.manojlo...@gmail.com> wrote: > > > except that only "small" problem is that i even don't know for what > > that thread was about :) > > > I'm receiving emails trough gmail and it can't follow thread this way > > definitely... > > > On Sat, Oct 10, 2009 at 5:39 PM, mdipierro > > wrote: > > > > I really appreciate when people report solved problem and change the > > > thread title as you did. :-) > > > Thank you Leandro. > > > > On Oct 10, 10:32 am, ProfessionalIT wrote: > > >> Perfect ! Massimo. > > > >> -- Leandro > > > -- > > "Only two things are infinite, the universe and human stupidity, and > > I'm not sure about the former."-Albert Einstein --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32639] please check trunks
there a lot of new things in trunk. Please check it. In particular: 1) cached uploads allow for progress bars (thanks AndCycle) 2) ingres support (thanks Chris) 3) legacy database support for db2, mssql (thanks Denes) 4) default setting of content-type (this may cause strange behavior in old apps when downloading images. please check it!) 5) new cron Please let me know if you tried and was ok with you or not. I would like to post a new version of web2py next week. Massimo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32640] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
>>Most people, including me, do not use email for posting/reading. We access the groups.google.com/group/web2py page directly. How do you know ? :) I use the web page most of the time but I like to set 'Email Updates to Me' for threads that I am interested in. Would changing the subject break that? On Oct 10, 3:22 pm, mdipierro wrote: > When you post about an issue and the issue is solved and you email a > response saying the issue is solved make sure you edit the subject and > append [SOLVED]. > > That is all. > > Most people, including me, do not use email for posting/reading. We > access the groups.google.com/group/web2py page directly. > > Massimo > > On Oct 10, 3:13 pm, Thadeus Burgess wrote: > > > Agreed, I do all communication through gmail, no way to change topic or > > follow topics, no clue what he was talking about :P > > > -Thadeus > > > On Sat, Oct 10, 2009 at 11:22 AM, Boris Manojlovic < > > > boris.manojlo...@gmail.com> wrote: > > > > except that only "small" problem is that i even don't know for what > > > that thread was about :) > > > > I'm receiving emails trough gmail and it can't follow thread this way > > > definitely... > > > > On Sat, Oct 10, 2009 at 5:39 PM, mdipierro > > > wrote: > > > > > I really appreciate when people report solved problem and change the > > > > thread title as you did. :-) > > > > Thank you Leandro. > > > > > On Oct 10, 10:32 am, ProfessionalIT wrote: > > > >> Perfect ! Massimo. > > > > >> -- Leandro > > > > -- > > > "Only two things are infinite, the universe and human stupidity, and > > > I'm not sure about the former."-Albert Einstein --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32641] Re: New slice on Setting up Paypal
I have added a PDF with the document, which includes some images that may make the information better understandable. Find its link for download at the end of this blog post: http://www.albendas.com/main/albendasitnews_eng/?p=5 Best regards, Benigno. On Oct 10, 5:00 pm, mdipierro wrote: > +1 > > On Oct 10, 2:04 am, Benigno wrote: > > > Hello, > > > I have posted a slice on Setting up Paypal with Web2py. You can > > find it here: > > >http://www.web2pyslices.com/main/slices/take_slice/9 > > > I will be posting a better formated document with some images to > > better understand it shortly. > > > One thing though, this was tested and programmed about 4 months > > ago, since then, Paypal has changed some of its APIs it seems, and > > some of the message names may have changed or no longer be available. > > This should be pretty basic to detect though. > > > Best regards, > > Benigno. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32642] Re: A simple patch to provide upload progress
@Massiom http://pastebin.com/f69e7b008 here is the patch include a working sample, by the way you got another indent error in copystream_progress :p On Oct 11, 3:43 am, mdipierro wrote: > @AndCycle > > I rearranged the code in trunk a bit. Could you check it still works? > Thanks again. > > Massimo > > On Oct 8, 5:14 am, AndCycle wrote: > > > thanks :) > > > I will take some free time to write a example base on trunk :p > > > On Oct 7, 10:24 pm, mdipierro wrote: > > > > Check again. I added it now. > > > > On Oct 7, 6:42 am, AndCycle wrote: > > > > > oops, the patch been cut by width restriction on mailing list lol > > > > > here is pastebinhttp://pastebin.com/f219d603b > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32643] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
IT does break it - Apparently, the content of the thread is not copied (so there is NO CONTEXT when the thread is email sent; that is, the FIRST item in the mailed topic is "SOlved! Thanks!" --- without anything else. On Sat, Oct 10, 2009 at 3:50 PM, mr.freeze wrote: > > >>Most people, including me, do not use email for posting/reading. We > access the groups.google.com/group/web2py page directly. > > How do you know ? :) I use the web page most of the time but I like > to set 'Email Updates to Me' for threads that I am interested in. > Would changing the subject break that? > > On Oct 10, 3:22 pm, mdipierro wrote: > > When you post about an issue and the issue is solved and you email a > > response saying the issue is solved make sure you edit the subject and > > append [SOLVED]. > > > > That is all. > > > > Most people, including me, do not use email for posting/reading. We > > access the groups.google.com/group/web2py page directly. > > > > Massimo > > > > On Oct 10, 3:13 pm, Thadeus Burgess wrote: > > > > > Agreed, I do all communication through gmail, no way to change topic or > > > follow topics, no clue what he was talking about :P > > > > > -Thadeus > > > > > On Sat, Oct 10, 2009 at 11:22 AM, Boris Manojlovic < > > > > > boris.manojlo...@gmail.com> wrote: > > > > > > except that only "small" problem is that i even don't know for what > > > > that thread was about :) > > > > > > I'm receiving emails trough gmail and it can't follow thread this way > > > > definitely... > > > > > > On Sat, Oct 10, 2009 at 5:39 PM, mdipierro > > > > wrote: > > > > > > > I really appreciate when people report solved problem and change > the > > > > > thread title as you did. :-) > > > > > Thank you Leandro. > > > > > > > On Oct 10, 10:32 am, ProfessionalIT wrote: > > > > >> Perfect ! Massimo. > > > > > > >> -- Leandro > > > > > > -- > > > > "Only two things are infinite, the universe and human stupidity, and > > > > I'm not sure about the former."-Albert Einstein > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32644] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
This isn't to TERRIBLY awful (at least not in gmail, with a folder for web2py group mails) - all you have to do is copy the topic (less the "[SOLVED]" and search for it; it's recent, so you can get to it fairly readily - but you do have to take a few steps to get to it On Sat, Oct 10, 2009 at 5:39 PM, Yarko Tymciurak wrote: > IT does break it - Apparently, the content of the thread is not copied (so > there is NO CONTEXT when the thread is email sent; that is, the FIRST item > in the mailed topic is "SOlved! Thanks!" --- without anything else. > > > On Sat, Oct 10, 2009 at 3:50 PM, mr.freeze wrote: > >> >> >>Most people, including me, do not use email for posting/reading. We >> access the groups.google.com/group/web2py page directly. >> >> How do you know ? :) I use the web page most of the time but I like >> to set 'Email Updates to Me' for threads that I am interested in. >> Would changing the subject break that? >> >> On Oct 10, 3:22 pm, mdipierro wrote: >> > When you post about an issue and the issue is solved and you email a >> > response saying the issue is solved make sure you edit the subject and >> > append [SOLVED]. >> > >> > That is all. >> > >> > Most people, including me, do not use email for posting/reading. We >> > access the groups.google.com/group/web2py page directly. >> > >> > Massimo >> > >> > On Oct 10, 3:13 pm, Thadeus Burgess wrote: >> > >> > > Agreed, I do all communication through gmail, no way to change topic >> or >> > > follow topics, no clue what he was talking about :P >> > >> > > -Thadeus >> > >> > > On Sat, Oct 10, 2009 at 11:22 AM, Boris Manojlovic < >> > >> > > boris.manojlo...@gmail.com> wrote: >> > >> > > > except that only "small" problem is that i even don't know for what >> > > > that thread was about :) >> > >> > > > I'm receiving emails trough gmail and it can't follow thread this >> way >> > > > definitely... >> > >> > > > On Sat, Oct 10, 2009 at 5:39 PM, mdipierro > > >> > > > wrote: >> > >> > > > > I really appreciate when people report solved problem and change >> the >> > > > > thread title as you did. :-) >> > > > > Thank you Leandro. >> > >> > > > > On Oct 10, 10:32 am, ProfessionalIT wrote: >> > > > >> Perfect ! Massimo. >> > >> > > > >> -- Leandro >> > >> > > > -- >> > > > "Only two things are infinite, the universe and human stupidity, and >> > > > I'm not sure about the former."-Albert Einstein >> >> >> > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32645] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
On Oct 10, 2009, at 1:22 PM, mdipierro wrote: > When you post about an issue and the issue is solved and you email a > response saying the issue is solved make sure you edit the subject and > append [SOLVED]. > > That is all. > > Most people, including me, do not use email for posting/reading. We > access the groups.google.com/group/web2py page directly. It would be nice if the (first) SOLVED posting included a statement of the problem and the solution (or at least a summary). --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32646] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
As long as changing the subject doesn't cancel the email updates then it will work for me. I use the email updates more to let me know that a new reply has been posted, then I go out to the web page. Thanks for checking. It would be nice if we could just forward solved threads to another place for reference. Sort of like 'promoting' them to a knowledge base. On Oct 10, 5:41 pm, Yarko Tymciurak wrote: > This isn't to TERRIBLY awful (at least not in gmail, with a folder for > web2py group mails) - all you have to do is copy the topic (less the > "[SOLVED]" and search for it; it's recent, so you can get to it fairly > readily - but you do have to take a few steps to get to it > > On Sat, Oct 10, 2009 at 5:39 PM, Yarko Tymciurak wrote: > > IT does break it - Apparently, the content of the thread is not copied (so > > there is NO CONTEXT when the thread is email sent; that is, the FIRST item > > in the mailed topic is "SOlved! Thanks!" --- without anything else. > > > On Sat, Oct 10, 2009 at 3:50 PM, mr.freeze wrote: > > >> >>Most people, including me, do not use email for posting/reading. We > >> access the groups.google.com/group/web2py page directly. > > >> How do you know ? :) I use the web page most of the time but I like > >> to set 'Email Updates to Me' for threads that I am interested in. > >> Would changing the subject break that? > > >> On Oct 10, 3:22 pm, mdipierro wrote: > >> > When you post about an issue and the issue is solved and you email a > >> > response saying the issue is solved make sure you edit the subject and > >> > append [SOLVED]. > > >> > That is all. > > >> > Most people, including me, do not use email for posting/reading. We > >> > access the groups.google.com/group/web2py page directly. > > >> > Massimo > > >> > On Oct 10, 3:13 pm, Thadeus Burgess wrote: > > >> > > Agreed, I do all communication through gmail, no way to change topic > >> or > >> > > follow topics, no clue what he was talking about :P > > >> > > -Thadeus > > >> > > On Sat, Oct 10, 2009 at 11:22 AM, Boris Manojlovic < > > >> > > boris.manojlo...@gmail.com> wrote: > > >> > > > except that only "small" problem is that i even don't know for what > >> > > > that thread was about :) > > >> > > > I'm receiving emails trough gmail and it can't follow thread this > >> way > >> > > > definitely... > > >> > > > On Sat, Oct 10, 2009 at 5:39 PM, mdipierro > >> > > > wrote: > > >> > > > > I really appreciate when people report solved problem and change > >> the > >> > > > > thread title as you did. :-) > >> > > > > Thank you Leandro. > > >> > > > > On Oct 10, 10:32 am, ProfessionalIT wrote: > >> > > > >> Perfect ! Massimo. > > >> > > > >> -- Leandro > > >> > > > -- > >> > > > "Only two things are infinite, the universe and human stupidity, and > >> > > > I'm not sure about the former."-Albert Einstein --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32647] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
You can - setup a filter on your gmail (or wherever) - grap from web2py@googlegroups.com with subject containing "[SOLVED]"; On Sat, Oct 10, 2009 at 6:12 PM, mr.freeze wrote: > > As long as changing the subject doesn't cancel the email updates then > it will work for me. I use the email updates more to let me know that > a new reply has been posted, then I go out to the web page. Thanks > for checking. > > It would be nice if we could just forward solved threads to another > place for reference. Sort of like 'promoting' them to a knowledge > base. > > On Oct 10, 5:41 pm, Yarko Tymciurak wrote: > > This isn't to TERRIBLY awful (at least not in gmail, with a folder for > > web2py group mails) - all you have to do is copy the topic (less the > > "[SOLVED]" and search for it; it's recent, so you can get to it fairly > > readily - but you do have to take a few steps to get to it > > > > On Sat, Oct 10, 2009 at 5:39 PM, Yarko Tymciurak > wrote: > > > IT does break it - Apparently, the content of the thread is not copied > (so > > > there is NO CONTEXT when the thread is email sent; that is, the FIRST > item > > > in the mailed topic is "SOlved! Thanks!" --- without anything else. > > > > > On Sat, Oct 10, 2009 at 3:50 PM, mr.freeze > wrote: > > > > >> >>Most people, including me, do not use email for posting/reading. We > > >> access the groups.google.com/group/web2py page directly. > > > > >> How do you know ? :) I use the web page most of the time but I like > > >> to set 'Email Updates to Me' for threads that I am interested in. > > >> Would changing the subject break that? > > > > >> On Oct 10, 3:22 pm, mdipierro wrote: > > >> > When you post about an issue and the issue is solved and you email a > > >> > response saying the issue is solved make sure you edit the subject > and > > >> > append [SOLVED]. > > > > >> > That is all. > > > > >> > Most people, including me, do not use email for posting/reading. We > > >> > access the groups.google.com/group/web2py page directly. > > > > >> > Massimo > > > > >> > On Oct 10, 3:13 pm, Thadeus Burgess wrote: > > > > >> > > Agreed, I do all communication through gmail, no way to change > topic > > >> or > > >> > > follow topics, no clue what he was talking about :P > > > > >> > > -Thadeus > > > > >> > > On Sat, Oct 10, 2009 at 11:22 AM, Boris Manojlovic < > > > > >> > > boris.manojlo...@gmail.com> wrote: > > > > >> > > > except that only "small" problem is that i even don't know for > what > > >> > > > that thread was about :) > > > > >> > > > I'm receiving emails trough gmail and it can't follow thread > this > > >> way > > >> > > > definitely... > > > > >> > > > On Sat, Oct 10, 2009 at 5:39 PM, mdipierro < > mdipie...@cs.depaul.edu > > > > >> > > > wrote: > > > > >> > > > > I really appreciate when people report solved problem and > change > > >> the > > >> > > > > thread title as you did. :-) > > >> > > > > Thank you Leandro. > > > > >> > > > > On Oct 10, 10:32 am, ProfessionalIT > wrote: > > >> > > > >> Perfect ! Massimo. > > > > >> > > > >> -- Leandro > > > > >> > > > -- > > >> > > > "Only two things are infinite, the universe and human stupidity, > and > > >> > > > I'm not sure about the former."-Albert Einstein > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32648] Re: stupid question: How to format a table.id in a form ? [ SOLVED ]
How about, you just reply and the last message contains the text [SOLVED], not in the title, but in the body. That way if you wanted to search for solved on the google group its possible, however it does not break gmail. Also, I think that if a topic has been solved, if it is lengthy at all, such as the solution was found after several conversations, then the solution should be posted by the original author as well. Making it easy for us to add these to the wiki, like freeze suggested, promoting them to a knowledge base. I plan to start adding some of the groups questions on the wiki when the wiki is ready. -Thadeus On Sat, Oct 10, 2009 at 6:23 PM, Yarko Tymciurak wrote: > You can - setup a filter on your gmail (or wherever) - grap from > web2py@googlegroups.com with subject containing "[SOLVED]"; > > > On Sat, Oct 10, 2009 at 6:12 PM, mr.freeze wrote: > >> >> As long as changing the subject doesn't cancel the email updates then >> it will work for me. I use the email updates more to let me know that >> a new reply has been posted, then I go out to the web page. Thanks >> for checking. >> >> It would be nice if we could just forward solved threads to another >> place for reference. Sort of like 'promoting' them to a knowledge >> base. >> >> On Oct 10, 5:41 pm, Yarko Tymciurak wrote: >> > This isn't to TERRIBLY awful (at least not in gmail, with a folder for >> > web2py group mails) - all you have to do is copy the topic (less the >> > "[SOLVED]" and search for it; it's recent, so you can get to it fairly >> > readily - but you do have to take a few steps to get to it >> > >> > On Sat, Oct 10, 2009 at 5:39 PM, Yarko Tymciurak >> wrote: >> > > IT does break it - Apparently, the content of the thread is not copied >> (so >> > > there is NO CONTEXT when the thread is email sent; that is, the FIRST >> item >> > > in the mailed topic is "SOlved! Thanks!" --- without anything else. >> > >> > > On Sat, Oct 10, 2009 at 3:50 PM, mr.freeze >> wrote: >> > >> > >> >>Most people, including me, do not use email for posting/reading. We >> > >> access the groups.google.com/group/web2py page directly. >> > >> > >> How do you know ? :) I use the web page most of the time but I like >> > >> to set 'Email Updates to Me' for threads that I am interested in. >> > >> Would changing the subject break that? >> > >> > >> On Oct 10, 3:22 pm, mdipierro wrote: >> > >> > When you post about an issue and the issue is solved and you email >> a >> > >> > response saying the issue is solved make sure you edit the subject >> and >> > >> > append [SOLVED]. >> > >> > >> > That is all. >> > >> > >> > Most people, including me, do not use email for posting/reading. We >> > >> > access the groups.google.com/group/web2py page directly. >> > >> > >> > Massimo >> > >> > >> > On Oct 10, 3:13 pm, Thadeus Burgess wrote: >> > >> > >> > > Agreed, I do all communication through gmail, no way to change >> topic >> > >> or >> > >> > > follow topics, no clue what he was talking about :P >> > >> > >> > > -Thadeus >> > >> > >> > > On Sat, Oct 10, 2009 at 11:22 AM, Boris Manojlovic < >> > >> > >> > > boris.manojlo...@gmail.com> wrote: >> > >> > >> > > > except that only "small" problem is that i even don't know for >> what >> > >> > > > that thread was about :) >> > >> > >> > > > I'm receiving emails trough gmail and it can't follow thread >> this >> > >> way >> > >> > > > definitely... >> > >> > >> > > > On Sat, Oct 10, 2009 at 5:39 PM, mdipierro < >> mdipie...@cs.depaul.edu >> > >> > >> > > > wrote: >> > >> > >> > > > > I really appreciate when people report solved problem and >> change >> > >> the >> > >> > > > > thread title as you did. :-) >> > >> > > > > Thank you Leandro. >> > >> > >> > > > > On Oct 10, 10:32 am, ProfessionalIT >> wrote: >> > >> > > > >> Perfect ! Massimo. >> > >> > >> > > > >> -- Leandro >> > >> > >> > > > -- >> > >> > > > "Only two things are infinite, the universe and human >> stupidity, and >> > >> > > > I'm not sure about the former."-Albert Einstein >> >> > > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32649] Re: SELECT - UTF-8 errors
On Oct11, 3:42am, leone wrote: > I have same string inserted in a table. > When I select them, I debug this error: > > File "/xx/xx/web2py/web2py/gluon/sql.py", line 2235, in > response > return self._db._cursor.fetchall() > OperationalError: Could not decode to UTF-8 column 'subject' with text > 'x i xxx' > > This is a problem of sql.py module. What can I do? > Thanks Did you ever try searching "utf8" in this group or in google? That is very likely a common utf8 issue. See this. http://groups.google.com/group/web2py/browse_frm/thread/e9bc715d7d10458a --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32650] Re: strip whitespace before validating fields
On Oct11, 4:21am, Thadeus Burgess wrote: > > > On Oct 10, 7:52 am, devnull wrote: > > > > Is there an option or a validator that will strip whitespace before > > > > applying remaining validators for a given field on a form? > > > > > Somewhat related: I tried the CLEANUP validator but the resulting > > > > variable still had characters like !...@#%^ in it. Maybe I > > > > mis-understood > > > > its purpose... perhaps it strips special characters for the other > > > > validators, but then when everything is done the original typed value > > > > gets sent? It would be cool if there were a validator that took a > > > > regex or a list of characters and stripped those from the input (so a > > > > phone field might ignore everything except digits). > > On Oct 10, 10:02 am, mdipierro wrote: > > I agree. Sometimes I think stripping should be a default for non-text, > > non-blob fields. Pros/cons? > > Breaks backwards compatability. So under our banner of web2pyism, we can't > do it. > > However, devnull, try this, this will alter the input before you validate it > through the form, so you can apply operators, such as stripping, or > .capitalize() or .upper() or anything really :P > > def decode(string, strip="!...@#$%^&*()"): > newstr = "" > for char in string: > if char not in strip: > newstr += char > return newstr > > def myaction(): > if request.vars: > request.vars.fieldname = decode(request.vars.fieldname) > form = SQLFORM(db.tablename) > > if form.accepts(request.vars, session): > response.flash = "yay" > elif form.errors: > response.flash = "nay" > else: > response.flash = "hey" > > -Thadeus > How about adding a new parameter for some old validators? That will not break backward compatibility. Here is how. class CLEANUP(Validator): def __init__(self,dust=None): # dust can be None, or a list of chars (aka string), or a regex. # If it is a string, it specifis the set of characters to be removed. # If omitted or None, defaults to removing whitespace. # If it is a regex, it removes chars met by the regex. self.dust=dust def __call__(self,value): # the implementation And we can add the new parameter dust for IS_IN_DB too. class IS_IN_DB(Validator): def __init__(self, .., dust=None): # mentioned above --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32651] How to Change the css style color and text of submit button on a crud.create form in controller
took me a while to dig up the answer/solution, maybe can save someone else some time form = crud.create(...) form=DIV( form, SCRIPT('''$(document).ready(function() { $("input[type=submit]").val("Share"); });'''), SCRIPT('''$(document).ready(function() { $("input[type=submit]").css({ color:'white', background:'blue', font: 'bold'}); });'''), ) return dict(form=form) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32652] Re: why doesn't this ajax call work? [RESOLVED -- updated web2py_ajax.html]
OK, now I found the real reason why my ajax wasn't working. Yes, the example I introduced above was, indeed, incorrect because it didn't have the right id. Mr. Freeze's is correct. However, this was not the root problem. The root problem was that I was using a version of the web2py_ajax.html from when I originally started developing my app a few months ago. That version is, apparently, out of date and didn't work properly. I updated it with a later version and voila, my ajax now works. So caveat emptor: if you're working on ajax, make sure your views folder has an updated version of web2py_ajax.html. In general, this may be an issue about releasing newer versions of web2py because the apps aren't updated automatically. Perhaps the ajax include should be one level up from apps? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32653] Re: How to Change the css style color and text of submit button on a crud.create form in controller
I wonder if we could encapsulate, simplify this with a decorator, something like: @button( color='white', background='blue', font='bold' ) form = crud.create(...) Something like this could be useful for something like @button( my_admin_style ) form = crud.create() @button( my_warning_style ) form = ... just thinking out loud On Sat, Oct 10, 2009 at 11:10 PM, Web2py-SuperFan wrote: > > took me a while to dig up the answer/solution, maybe can save someone > else some time > >form = crud.create(...) >form=DIV( > form, > SCRIPT('''$(document).ready(function() { > $("input[type=submit]").val("Share"); > });'''), > SCRIPT('''$(document).ready(function() { > $("input[type=submit]").css({ > color:'white', > background:'blue', > font: 'bold'}); > });'''), > ) > > return dict(form=form) > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---
[web2py:32654] Re: SELECT - UTF-8 errors
Yes, I have added .encode('utf8') to my default Field('subject','text', default=u''.encode('utf8')), On 11 Ott, 01:53, Iceberg wrote: > On Oct11, 3:42am, leone wrote: > > > I have same string inserted in a table. > > When I select them, I debug this error: > > > File "/xx/xx/web2py/web2py/gluon/sql.py", line 2235, in > > response > > return self._db._cursor.fetchall() > > OperationalError: Could not decode to UTF-8 column 'subject' with text > > 'x i xxx' > > > This is a problem of sql.py module. What can I do? > > Thanks > > Did you ever try searching "utf8" in this group or in google? That is > very likely a common utf8 issue. See this. > > http://groups.google.com/group/web2py/browse_frm/thread/e9bc715d7d10458a --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~--~~~~--~~--~--~---