very cool!!! :)
On Jun 30, 2:41 am, niknok wrote:
> In the validation example, I entered a single character in the Bio
> and was allowed to proceed to the next field despite the
> db.person.bio.requires = IS_LENGTH(minsize=5, maxsize=200). You made
> a note about "Client side validation is not
On 06/29/2011 10:51 PM, pbreit wrote:
Or this if you can get by with them only being available on "localhost":
# by default give a view/generic.extension to all actions from localhost
# none otherwise. a pattern can be 'controller/function.extension'
response.generic_patterns = ['*'] if request.
Clarification regarding the bio field with requires. It does let me
proceed to the next step, but will not be allowed to submit the data
after validation unless i meet the requires statement.
A bit confusing since some fields will allow me to move to next step.
One more thing, is there going to b
Hello All!
See I right that the plugin system can't handle language files for the
plugins or I miss something?
It could be good to be able to have the language files for plugins...
On 30/06/2011 10:07, szimszon wrote:
Hello All!
See I right that the plugin system can't handle language files for the
plugins or I miss something?
It could be good to be able to have the language files for plugins...
have you seen
http://www.web2py.com/book/default/chapter/13?search=plugin#
here is an interesting article about source code licenses
http://gskinner.com/blog/archives/2008/07/source_code_lic_1.html
the author in summary says
"I would strongly encourage developers to release shared code under
the MIT license."
and
"I would also encourage developers to petition the owners
On Thu, Jun 30, 2011 at 2:55 AM, Jonathan Lundell wrote:
> On Jun 29, 2011, at 1:18 PM, Richard Arts wrote:
>>
>> Can somebody point out to me how to use the request.env.http_referrer
>> to link to the previous page?
>>
>> So far I have tried the following in the template file:
>> {{=A('Back', _hr
Did not work. And admin did not recognize it too...
While I think frameworks are best under BSD/MIT, this article seems mostly
about flash and is not very compelling. As well as old.
If you pass, for example, an auth_user record to a view, you can view all the
fields of that record by changing the extension. If you're passin locals() you
can view even more. This is because the generics are designed to display
everything that they can. Helpful during development but not appro
Does web2py support Multiple Languages. So lets say I create a system
that is all in English, How would i translate it into french Italian
Spanish.
Yes, if you read the book, you've seen about i18n here:
http://www.web2py.com/book/default/chapter/04#T-and-Internationalization
2011/6/30 stargate
> Does web2py support Multiple Languages. So lets say I create a system
> that is all in English, How would i translate it into french Italian
>
Still nop!
I also try to put it in the if table == like this :
if table == 'ref_fnaregistry':
#redirect(URL(request.application,c='default',f='index.html'))
form.update(_class='no_trap',
_action=URL('default','creation.html'),args=1)
return dict(form=fo
Even without client side validation, the server side will perform at the end
of submission.
The client-side validation, for now, just check if a field is required, i
did not implemented yet the other kind of client validation.
I guess you can use factory in the normal way, PowerFormWizard.factory
Minor update:
110630
display the number of the uploadable and the uploaded files on upload group
list
110628
the upload and downloaed links of the upload groups has now a title='...'
with the best before date
And *Like* button on https://trac.oregpreshaz.eu/linux/wiki/ul
Could we have a down
Thanks for this hint, but that doesn't seem to work.
If I apply this to the field in either model or controller, i get
following error:
File "gluon/sqlhtml.py", line 782, in __init__
File "gluon/dal.py", line 5247, in formatter
File "gluon/validators.py", line 807, in formatter
TypeErr
On Thu, Jun 30, 2011 at 9:50 AM, szimszon wrote:
> Could we have a download count on *appliances* page?
>
Not yet, I am working on web2yslices2.0, which will probably work as an
appliance directory, this will be included...
Now, I host my projects in bitbucket, and I link ethe download to there
I did something similar to demonstrate common vulnerabilities, such as SQL
injection and changing hidden values in forms before submission. It was
really tough to make this app with web2py, as I had to skirt around most of
the framework to make it happen. This is a GOOD THING though. I learned a
I added an unindexed string type like this:
from google.appengine.ext import db as gae
db._adapter.types['noindex'] = (lambda: gae.StringProperty(multiline=True,
indexed=False))
Is there a better way?
No, the code should look like this:
def create_fvte():
table = request.args(0)
crud.settings.formstyle='divs'
form = crud.create(db[table])
form.update(_class='no_trap',
_action=URL('default','create_fvte.html',args=request.args))
if form.accepts(request.vars, session):
Now it works!!!
I had try what you explained... I didn't just not explain everything
completly maybe...
There is only an artefact. The next solution that you propose breaks the
normal workflow of navigation... The user can't go back with the nav
backward arrow... Maybe we could use "javascript:vo
We had a long discussion about this several months ago, and as a result, the
license was changed from GPL (with commercial exception) to LGPL. I think
the idea was that LGPL should allow usage of the framework along with apps
and libraries of any license type while prohibiting any closed
source
You're welcome.
Yeah, you might have to play around with the JS a bit, but hopefully this
points you in the right direction.
The problem with the server side redirect is that the jQuery ajax function
receives the redirect response and then makes the redirect request via ajax
again, and then
Thank you both for the help and advice, things are working perfectly
now.
On Jun 30, 9:25 am, Ross Peoples wrote:
> I did something similar to demonstrate common vulnerabilities, such as SQL
> injection and changing hidden values in forms before submission. It was
> really tough to make this app
Hello,
I am having hard time to refresh component I don't know if it is my
response.js or my setup or 1.97.1 issue :
response.js="web2py_component(URL(c='ref',f='creation'),'two')"
CONTROLLER
def creation():
if not request.args:
response.flash = T('please fill out the form')
a =
>
> I think frameworks are best under BSD/MIT
so you agree :)
the fact that it is written by a flash developer a few years ago doesn't
mean that this is not relevant information
prohibiting any closed source/commercial forks of web2py
DAL and template system can be used standalone
what if I wa
On Thu, Jun 30, 2011 at 1:52 PM, Vasile Ermicioi wrote:
> DAL and template system can be used standalone
> what if I want to use them with bottle (MIT) or flask(BSD) and make a
> hybrid framework and distribute them (in commercial projects too)?
>
I guess you can create a comercial product, but
>
> I guess you can create a comercial product, but not a comercial framework.
what about an opensource framework :) e.g. ( bottle+dal+template+rocket) ?
anyway, I think another license change (to MIT) will be welcome
On Thu, Jun 30, 2011 at 2:05 PM, Vasile Ermicioi wrote:
> what about an opensource framework :) e.g. ( bottle+dal+template+rocket) ?
Martin Mulone started a project for that
https://bitbucket.org/mulonemartin/web2tools/overview
--
--
Bruno Rocha
[ About me: http://zerp.ly/rochacbruno ]
On Thursday, June 30, 2011 12:39:53 PM UTC-4, Richard wrote:
>
> Hello,
>
> I am having hard time to refresh component I don't know if it is my
> response.js or my setup or 1.97.1 issue :
>
> response.js="web2py_component(URL(c='ref',f='creation'),'two')"
>
You can't put a call to the URL() fu
great, as always, I thought and it is already done :)
so forks are allowed, or... ?
On Thursday, June 30, 2011 1:05:47 PM UTC-4, elffikk wrote:
>
> I guess you can create a comercial product, but not a comercial framework.
>
>
> what about an opensource framework :) e.g. ( bottle+dal+template+rocket) ?
>
I think you can do that, but I don't think you could make the entire
fr
On Thursday, June 30, 2011 12:52:06 PM UTC-4, elffikk wrote:
>
> I think frameworks are best under BSD/MIT
>
> so you agree :)
> the fact that it is written by a flash developer a few years ago doesn't
> mean that this is not relevant information
>
>
> prohibiting any closed source/commercial
Ok, it works now but I get None in place of the reloaded component... I
thought it could be the Tabs plugin so I remove the initiation script but
still get None...
Any idea?
On Thu, Jun 30, 2011 at 1:13 PM, Anthony wrote:
> On Thursday, June 30, 2011 12:39:53 PM UTC-4, Richard wrote:
>>
>> Hell
I'm having the same issue. Where do I have to include all this? Is
there some other workaround for this? It would be great if we could
use Sphinx for documenting out Web2Py apps.
Thanks for any help.
On May 28, 5:18 pm, Massimo Di Pierro
wrote:
> controllers and models in web2py are written in
Like this it pass, but it takes time and it load the entire site before
finally return the updated component...
response.js="web2py_component(URL(c='ref',f='creation#tabs-2'),'two')"
Richard
On Thu, Jun 30, 2011 at 1:25 PM, Richard Vézina wrote:
> Ok, it works now but I get None in place of th
Not sure. Isn't that the wrong URL for your component? Shouldn't it be
f='create_ftve', plus args=[tablename]?
On Thursday, June 30, 2011 1:25:13 PM UTC-4, Richard wrote:
> Ok, it works now but I get None in place of the reloaded component... I
> thought it could be the Tabs plugin so I remove
Kind of the exact same problem we already solve...
The propagation has pretty problematic behavior in this peculiar case
Richard
On Thu, Jun 30, 2011 at 1:32 PM, Richard Vézina wrote:
> Like this it pass, but it takes time and it load the entire site before
> finally return the updated compone
Ok, my mistake... I had try with create_fvte before but with the URL in the
js call so I thought it were not working with it.
Richard
On Thu, Jun 30, 2011 at 1:34 PM, Anthony wrote:
> Not sure. Isn't that the wrong URL for your component? Shouldn't it be
> f='create_ftve', plus args=[tablename]
Interresting too in the fix to use Sphynx to document app...
Richard
On Thu, Jun 30, 2011 at 1:29 PM, Dan wrote:
> I'm having the same issue. Where do I have to include all this? Is
> there some other workaround for this? It would be great if we could
> use Sphinx for documenting out Web2Py app
Martin did something great, but I would include template too,
because I prefer web2py's template system
Hi
I have an app I've been working on and upgraded my system to 1.97.1
today. Since then I'm getting the following with an AJAX call for json
data:
Traceback(most recent call last):
File"gluon/restricted.py",line192,inrestricted
File"C:/dev/web2py/applications/InfoCenter/controllers/admi
Any ideas on this one? Has anyone else had problems with LOAD(ajax=False) in
trunk? I tried switching it to deepcopy and got same error. I also tried
putting it in a try/except but could not find anything. Could my request
have something funky in it?
You answer your own post... So many may consider you find your own answer...
Maybe start a other thread could help.
Richard
On Thu, Jun 30, 2011 at 3:10 PM, pbreit wrote:
> Any ideas on this one? Has anyone else had problems with LOAD(ajax=False)
> in trunk? I tried switching it to deepcopy an
Thanks!
I take a look, then return here =)
# ---
# Bruno Barbosa
# Web Developer - Linux user and Free Software Enthusiast
# http://algoritmizando.com
# http://twitter.com/bruninbsb
# ---
2011/6/30 pbreit
> Check out Clou
Hi,
I want to use a SQLFORM with a checkbox. I have tried
... Field('my_question',
requires=[IS_IN_SET([T('Yes'),T('No')]),],
widget=SQLFORM.widgets.checkboxes.widget,
default=T('No'),
),...
I got a nice form with the German translations 'Ja' and 'Nein'.
But now I did not get the English
Hi,
is it possible to create a new table with an id-field not starting with 1.
I think it would be better to have numbers of equal length.
And - if it's possible - does it reduce efficiency?
Regards., Martin
IS_IN_SET( [ ('Y',T('Yes')), ('N',T('No')) ] )
Is in set, can receive a list of tuples, where first element is value,
second is text.
On Thu, Jun 30, 2011 at 4:31 PM, Martin Weissenboeck wrote:
> Hi,
>
> I want to use a SQLFORM with a checkbox. I have tried
>
> ... Field('my_question',
>
> requi
I think it will depend of your database backend and how you setup your
sequence generating... Web2py by default will create a basic sequence then
you should go in your database management software (ex.: pgAdmin for
postgres) to setup the proper caracteristic of your sequence...
Your may override t
Great, thank you - it solves the "_value"-problem.
But the other problem is not solved: I get only the translated version
(German), not dependig on the selected language.
I have tried it with T.force('fr-fr') [there is no French translation]. I
have expected 'Yes' and 'No', but I got again 'Ja' an
Hello,
Is it possible to declare UNIQUE constraint over many fields and how...
Does using IS_NOT_IN_DB() on the differents fields will work?
...num_part1.requires=IS_NOT_IN_DB(db((db.ref_fnaregistry.num_part1==request.vars.num_part1)
&
(db.ref_fnaregistry.num_part2==request.vars.
http://web2py.com/book/default/chapter/04?search=default+language#T-and-Internationalization
Look at default language in this page...
Also default depend of you browser setting...
Richard
On Thu, Jun 30, 2011 at 3:55 PM, Martin Weissenboeck wrote:
> Great, thank you - it solves the "_value"-pr
I just tested it and works perfectly.
Are you sure do you have the string translated in language file?
My test:
T.force('pt-br')
print T.accepted_language # printed ok pt-br in terminal
myset = [ ('Y', T('Yes')), ('N', T('No')) ]
db.define_table('question',
Field('my_question',
Reminder :
When 2 components have to be refresh with on this schema :
"web2py_component('%s',target)" % URL()
response.js="web2py_component('%s','two');" %
URL('ref','create_fvte',args='ref_vregistry')
response.js+="web2py_component('%s','three');" %
URL('ref','create_fvte',args='ref_tregistry')
Thanks for pointing this out Anthony - I'll try to find time to update my
slice & demo app soon.
~Brian
Yes, I have tried it too and the translation works very fine. But my problem
is: how to get the original strings 'Yes' and 'No'
I have forced a language with no translation (in my example
T.force('fr-fr')) and I thought, this would give the original strings. But I
got again the German strings. T.ac
Thank you for your answer.
I am using the built-in database, sqlite3. Where can I find the "sequence"?
2011/6/30 Richard Vézina
> I think it will depend of your database backend and how you setup your
> sequence generating... Web2py by default will create a basic sequence then
> you should go in
Well, length of an integer field is always the same...
but I understand what you want to mean, because I am on the same
situation
I guess you are looking for an ID to identify records, but It's not
convenient that the ID indicates the order of creation
In my case, is the affiliate ID, and I've b
pbreit wrote:
The filename that Web2py is giving my uploaded images is too long. Is it
possible to make it shorter?
For example (i need them to be under 150 chars):
item.image.8651e61b27b66998.6974656d2e696d6167652e396363373962663466616535313834392e3533353434313566333233323331333432653461353034
Yeah, I did find your original thread after some searching. And wondered if
it might be worth either shortening outright or making it configurable. I've
implemented 50 chars which seems like plenty to me.
By far the easiest is to use id and not worry about it.
If it's that important, I would suggest leaving id as-is and either adding a
new field or using a virtual field that does a simple hash. I've seen hashes
as simple as multiplying by a small prime number like 1007.
So:
Field('bigid', 'integ
UNIQUE applies at the database level. IS_NOT_IN_DB applies during form
validation.
I'm not sure that's going to work. Maybe a custom validator?
http://web2py.com/book/default/chapter/07#Custom-Validators
IS_NOT_IN_DB does take a DAL Set object as the first argument, so you can
limit the records checked to a particular set within the table (see
http://web2py.com/book/default/chapter/07#Database-Validators). However, I'm
not quite sure what you're trying to do here.
On Thursday, June 30, 2011 4:2
I'm still having trouble editing records in appadmin due to a foreign key
constraint. Even though I'm logged in as auth_user.id=5, it's trying to set
modified_by=0. This was in trying to update a custom auth_user table which
has an auth.signature.
Traceback (most recent call last):
File "/op
Hi
I'm looking at doing a neural net 20 questions type program at some
stage, but still having difficulty with the basics.
Currently if I do a dropdown field, it won't let me enter the data
unless the question on the NEXT screen is the same as this one.
I know it's something to do with the fact tha
Hello! I've been away for a while but am diving back into web2py for a
new project. I want to host my Crud forms in jqueryui dialogs so I
need to hide the submit button. I know I can do it using
form.element("input",_type="submit")["_style"] = "display:none;"
trickery but I want to avoid extra pro
Both slice & bitbucket repo should be fixed to work with web2py 1.97.1 now -
Thanks Richard for pointing this out and Anthony for helping to explain the
problem. Let me know if there are more issues.
~Brian
On Thu, Jun 30, 2011 at 4:15 PM, Anthony wrote:
> IS_NOT_IN_DB does take a DAL Set object as the first argument, so you can
> limit the records checked to a particular set within the table (see
> http://web2py.com/book/default/chapter/07#Database-Validators). However,
> I'm not quite sure what yo
On Thursday, June 30, 2011 9:43:39 PM UTC-4, Nick Arnett wrote:
>
>
>
> On Thu, Jun 30, 2011 at 4:15 PM, Anthony wrote:
>
>> IS_NOT_IN_DB does take a DAL Set object as the first argument, so you can
>> limit the records checked to a particular set within the table (see
>> http://web2py.com/book
On Thu, Jun 30, 2011 at 6:43 PM, Nick Arnett wrote:
>
>
> On Thu, Jun 30, 2011 at 4:15 PM, Anthony wrote:
>
>> IS_NOT_IN_DB does take a DAL Set object as the first argument, so you can
>> limit the records checked to a particular set within the table (see
>> http://web2py.com/book/default/chapte
On Thu, Jun 30, 2011 at 7:00 PM, Anthony wrote:
>
>
> I don't think web2py automatically creates any indexes -- see
> http://web2py.com/book/default/chapter/06#Indexes.
>
>
It has to! Can't have primary keys without them. But I see what you mean,
looking at the docs.
I guess I will just use th
about the slices... some of us are writing a book on recipes and I we
are using some ideas from the slices. I am finding a lot of good ideas
but some of the slices are old and can be improved a lot using new
syntax. I cannot share the text of the book for copyright issue but I
will share the code e
Custom Validator still seems like the best option:
http://web2py.com/book/default/chapter/07#Custom-Validators
Although I think unique_together is implemented via db constraints.
That seems like a very remote scenario so probably not outlandish that it
takes a little code.
Postgres, at least, a
Does that mean anything that goes in the book cannot be posted and modified
elsewhere? I'd much rather see a more permissive resource. The copyright and
licensing issues in this community are unfortunate to say the least.
Everything above the "if form.accepts()" is run each time the submit button
is pressed.
I can't think of the best way to implement this off-hand. It does seem like
you could do it all in one controller.
There's a pretty old survey app which might give you some ideas:
http://www.web2py.com/appli
Does anyone here edit records in /appadmin on a postgres db? It should work,
right?
On Thu, Jun 30, 2011 at 11:46 PM, pbreit wrote:
> Does that mean anything that goes in the book cannot be posted and modified
> elsewhere? I'd much rather see a more permissive resource. The copyright and
> licensing issues in this community are unfortunate to say the least.
Massimo is not refe
https://github.com/MisterRager/DOMination
Yes, I was concerned with the other book. But it'd also be nice if the Book
content could be used in different ways, too.
Yor're facing to a reported bug. In the bug report you can find a workaround
to continue working: http://code.google.com/p/web2py/issues/detail?id=319
2011/6/30 Jim Steil
> Hi
>
> I have an app I've been working on and upgraded my system to 1.97.1 today.
> Since then I'm getting the following
80 matches
Mail list logo