Re: [web2py:37222] Re: Markdown problem

2009-12-15 Thread Johann Spies
2009/11/26 mdipierro mdipie...@cs.depaul.edu: I took a second look. WIKI('this bis/b a test').xml() 'pthis lt;bgt;islt;/bgt; a test/p\n' WIKI('this bis/b a test',safe_mode=True).xml() 'pthis [HTML_REMOVED]is[HTML_REMOVED] a test/p\n' WIKI('this bis/b a test',safe_mode=False).xml() 'pthis

[web2py:37345] Online database designer

2009-12-16 Thread Johann Spies
I can't find the graphical online sql database designer from which I could get web2py model-code any more. Is there still one available like the one at http://ondras.zarovi.cz/sql/demo/ that can be used with web2py? Regards Johann -- You received this message because you are subscribed to the

[web2py:37349] Re: Online database designer

2009-12-16 Thread Johann Spies
Apologies, I found it: http://gaesql.appspot.com/ Sorry for the noise. Johann 2009/12/16 Johann Spies johann.sp...@gmail.com: I can't find the graphical online sql database designer from which I could get web2py model-code any more.  Is there still one available like the one at http

[web2py:37431] Web-based shell problem in 1.74.3

2009-12-16 Thread Johann Spies
The following work in the commandline based shell: for it in db().select(db.instansie.naam): ... print it ... Row {'naam': 'Universiteit van Stellenbosch'} The same in the web-based shell: Out[26]: Traceback (most recent call last): File input, line 1, in module File

Re: [web2py:37432] Re: Switch from http to https within app

2009-12-16 Thread Johann Spies
I think whether to use https and/or https should be handled outside the application. I would like it to be easily possible to handle for example all logins (where passwords are used) through https while the rest could be http. Because I don't know how to handle that within the application at

Re: [web2py:37505] Re: Web-based shell problem in 1.74.3

2009-12-17 Thread Johann Spies
2009/12/17 mdipierro mdipie...@cs.depaul.edu: In the web based shall can you try: print db print db.instansie print db.instansie.naam what do you get? which os? web2py version? binary or source? Last question first: This is on a Debian 64-bit system on which I unpacked web2py_src.zip.

Re: [web2py:37510] Re: Markdown problem

2009-12-18 Thread Johann Spies
2009/12/15 mdipierro mdipie...@cs.depaul.edu: XML(gluon.contrib.markdown.WIKI (page.body,safe_mode=False),sanitize=True)}} should be XML(gluon.contrib.markdown.WIKI(page.body,safe_mode=False).xml (),sanitize=True)}} Thanks. Now the error message is gone. As a test the following kode:

[web2py:37646] How to limit access to items in static?

2009-12-22 Thread Johann Spies
I use static inter alia for a few static html-pages linked to items in a wiki. Access to the wiki is limited to logged in users but if the url to the file in static is known it can be used to bypass those controls. How do I protect it? Regards Johann -- You received this message because you

[web2py:37654] Markdown syntax for tables?

2009-12-22 Thread Johann Spies
| 111.111.128.205 | Simon le Roux | | computer2.com | 111.111.128.206 | Johann Spies | But what I get is this: |Rekenaar | IP adres | Eienaar | | -- | | -- | | computer1.com | 111.111.128.205

Re: [web2py:37727] Re: How to limit access to items in static?

2009-12-22 Thread Johann Spies
2009/12/22 mdipierro mdipie...@cs.depaul.edu: You can use routes but the rule is: - if it is public goes in static - if it requires access control goes in uploads Thanks for the replies. If you don't mind, I would like advice on the following situation: I need restricted access to parts of

Re: [web2py:37748] Re: How to limit access to items in static?

2009-12-23 Thread Johann Spies
Thanks! Johann -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com. For more options, visit this group

Re: [web2py:37756] Re: Postgresql-types limited by web2py :(

2009-12-23 Thread Johann Spies
OK. Apologies. I forgot I can specify the length. Do you have documentation on SQLCustomType somewhere. I did quick search in your book and could not find any reference to it. Regards. Johann -- You received this message because you are subscribed to the Google Groups web2py-users group. To

Re: [web2py:37837] Re: Happy Holidays

2009-12-25 Thread Johann Spies
2009/12/25 KMax mkostri...@gmail.com: Warm wishes from cold Russia! And from warm South Africa! -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this group, send

[web2py] How to avoid duplicate entries?

2010-01-11 Thread Johann Spies
I am trying to sanitise data from different sources programatically. The following function is part of my effort: def artikel(datum,ti,wod_id,publ_id,di): titel = ti.strip().upper() if db(db.artikel.titel == titel).count() 1: # Is titel already in database? artikel_id =

Re: [web2py] Re: How to avoid duplicate entries?

2010-01-11 Thread Johann Spies
Thanks. That explains it. Johann -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com. For more options,

[web2py] web2py shell in emacs?

2010-01-12 Thread Johann Spies
Is there a way to tell emacs to use web2py's shell and environment for when in python mode? Regards Johann -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this

[web2py] Large datasets

2010-01-14 Thread Johann Spies
Is web2py suitable if I want to work with large datasets? I am currently developing a database and want to use web2py to make it available to the client. Up to now I was using the shell and appadmin interfaces to the databasis. When trying out the webgrid-slice from

[web2py] DAL query: limit ?

2010-01-14 Thread Johann Spies
What is the equivalent in DAL for l = db.executesql(select id from artikel limit 10;) Regards Johann -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this group,

Re: [web2py] Re: DAL query: limit ?

2010-01-14 Thread Johann Spies
Thanks - also for your answer on my other question about large datasets. 2010/1/14 mdipierro mdipie...@cs.depaul.edu: l = db().select(db.artikel.id,limitby=(0,10)) On Jan 14, 9:19 am, Johann Spies johann.sp...@gmail.com wrote: What is the equivalent in DAL for l = db.executesql(select id

[web2py] web2py and apache with mulitple sites

2010-01-20 Thread Johann Spies
The script in http://www.web2pyslices.com/main/slices/take_slice/29 works well when web2py is in the server root. I want to install web2py on a server that already has a php-site. I have tried and modify the apache configuration to one below (I tried it with and without the 'Alias' line but have

Re: [web2py] Re: Large datasets

2010-01-21 Thread Johann Spies
2010/1/15 mr.freeze nat...@freezable.com: WebGrid can handle large datasets as it limits the query by the page size if the datasource is a Set or Table(s).  The performance hit will come in when the filter row is enabled since each filter is a query for all distinct values in a field. I would

Re: [web2py] Re: web2py and apache with mulitple sites

2010-01-21 Thread Johann Spies
2010/1/21 Graham Dumpleton graham.dumple...@gmail.com: As asked in the thread:  http://groups.google.com/group/web2py/browse_frm/thread/6ae2a411d79ade50 where similar question was asked, you need to indicate: What needs to control the root page of the web server, a PHP script or

[web2py] SQLTABLE: how to customise it?

2010-01-21 Thread Johann Spies
I would like the table produced by SQLTABLE to have different column labels (e.g. Name for db.person.name). How do I do it? Also: I would like the output of SQLTABLE to provide links to individual records simliar to what appadmin does. I could not fully understand the code appadmin uses to

Re: [web2py] Re: SQLTABLE: how to customise it?

2010-01-21 Thread Johann Spies
SQLTABLE(rows,headers = {'table.field':'Label Field', }) On Jan 21, 7:36 am, Johann Spies johann.sp...@gmail.com wrote: I would like the table produced by SQLTABLE to have different column labels (e.g. Name for db.person.name).  How do I do it? Also: I would like the output of SQLTABLE

Re: [web2py] Re: Cherokee problem

2010-01-22 Thread Johann Spies
2010/1/21 Ivan P ivanv...@gmail.com: Although, I take my words back. My way is not the simplest. =) But it is not hard at all and is powerful. Thanks. I will try it. Regards Johann -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to

Re: [web2py] Re: How to limit access to items in static?

2010-01-22 Thread Johann Spies
2010/1/20 mdipierro mdipie...@cs.depaul.edu: You should not block access to thinks that are in static. Things in static should be considered ublic by default so that you can ask the web server to serve then and by-pass web2py. This is an optimization that you will need in production and cannot

[web2py] Re: [web2py:36899] Creating a CSV file from data

2010-01-25 Thread Johann Spies
2009/12/9 Thadeus Burgess thade...@thadeusb.com: Is there something wrong with the following? results = db(db.table.field == searchvar)(db.table.field2 == searchvar2).select() results.export_to_csv(outputfile, delimiter=',', quotechar='', qouting=csv.QOUTE_MINIMAL, represent=False) I

Re: [web2py] Re: How to limit access to items in static?

2010-01-26 Thread Johann Spies
2010/1/22 mdipierro mdipie...@cs.depaul.edu: You get invalid requests if the url is wrong or contains invalid chars (the filename cannot contain special chars or spaces, only alphanumeric and -). Thanks. It was not that easy to find the correct url, but in the end I found it. I have a

[web2py] Postgresql interface buggy

2010-01-27 Thread Johann Spies
It has happened several times now that I make changes in models/db.py to the structure of a table (e.g. changing the type of a field) and then web2py does not write the changes to the database (Postgresql) and in the end one ends up with a situation that you have to do changed using another

[web2py] wmd

2010-01-28 Thread Johann Spies
Thadeus mentioned that he used WMD on his blog. I have tried to get it working by putting the following in layout.hml: script type=text/javascript // to set WMD's options programatically, define a wmd_options object with whatever settings // you want to override. Here are the defaults:

Re: [web2py] Postgresql interface buggy

2010-01-28 Thread Johann Spies
On 28 January 2010 00:15, Thadeus Burgess thade...@thadeusb.com wrote: This is most likely a bug, would you be willing to provide more information on the matter? Example. I have changed the type of a field from string (1024) to 'text'. For simplicities sake, drop your tables with the DAL by

Re: [web2py] Re: wmd

2010-01-29 Thread Johann Spies
Thanks! Johann -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com. For more options, visit this group

[web2py] ProgrammingError: there is no unique constraint matching given keys for referenced table scopus_rou

2010-01-29 Thread Johann Spies
The data of the following table will come from 4 other: (db.scopus_rou, db.cab_rou, db.pubmed_rou, db.wos_rou) In each record I want to indicate from which of those the data of that record came. The last four fields are supposed to do that. In each case at least three of them might be empty.

Re: [web2py] Re: ProgrammingError: there is no unique constraint matching given keys for referenced table scopus_rou

2010-01-29 Thread Johann Spies
On 29 January 2010 22:33, mdipierro mdipie...@cs.depaul.edu wrote: can we see the definition of db.scopus_rou? What database engine? Database Engine: Postgresql. Here is the definition for scopus_rou: db.define_table(scopus_rou, Field(Authors, 'text'),

Re: [web2py] Re: ProgrammingError: there is no unique constraint matching given keys for referenced table scopus_rou

2010-01-29 Thread Johann Spies
On 29 January 2010 23:24, Johann Spies johann.sp...@gmail.com wrote: On 29 January 2010 22:33, mdipierro mdipie...@cs.depaul.edu wrote: can we see the definition of db.scopus_rou? What database engine? Your question helped me to remember: This was the table I recreated through psql then web2py

Re: [web2py] Postgres Log Shipping

2010-01-29 Thread Johann Spies
On 29 January 2010 22:50, Thadeus Burgess thade...@thadeusb.com wrote: Can anyone suggest a tutorial for log shipping to another database using postgresql ? If you mean by log shipping the method of using logs of sql-transactions to duplicate a database on another server you can search for

[web2py] Unreliable csv-download

2010-01-30 Thread Johann Spies
It happened more than once that a csv-export using appadmin resulted in incomplete data both with Postgresql-backend and sqlite. This one was on sqlite: Selected records: 139413 csv-exported (first effort): 287 records. csv-exported (second effort) 216 records This after a lot of time and

[web2py] Memory (thread?) problems. Is web2py suitable for large datasets?

2010-02-03 Thread Johann Spies
I am working with relatively large datasets (up to 45 records) an even when I try to minimize the memory usage by not doing a select on all the fields I get this error on a 4G ram computer with a dataset of about 15 records): lys = db().select(db.wos_rou.id) Exception in thread Thread-27:

Re: [web2py] Memory (thread?) problems. Is web2py suitable for large datasets? [Solved]

2010-02-03 Thread Johann Spies
On 3 February 2010 21:17, Wes James compte...@gmail.com wrote: It might make a difference on the DB you are using.  Which are you using sqlite, postgresql, mysql??  What OS?  As a side note if you are using windows, win32 only uses a little over 3gig as it uses the other for system use.  But

[web2py] form - redirect - where are the variables?

2010-02-08 Thread Johann Spies
I want to use a form to build a query for a search function and do not understand the communication between the different functions. I have: def index(): form = FORM(TABLE(TR('Field:','', SELECT( OPTION('title', _field = 1),

Re: [web2py] Re: form - redirect - where are the variables?

2010-02-08 Thread Johann Spies
You have a few problems, fixed below hopefully Thanks Massimo! Regards Johann -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group, send email to web...@googlegroups.com. To unsubscribe from this group, send email to

Re: [web2py] Re: form - redirect - where are the variables?

2010-02-09 Thread Johann Spies
Your corrections helped me to understand the handling or the request vars better but I still have the original problem: Traceback (most recent call last): File /home/js/web2py/gluon/restricted.py, line 173, in restricted exec ccode in environment File

[web2py] Login mutliple times?

2010-02-09 Thread Johann Spies
I have a website where some documents require login to be accessed. Some of the visitors to the site complained of having to login multiple times and today, when I did not access the site as administrator, I experienced the same: Log in at first and then when I access the document, I was again

Re: [web2py] Re: Login mutliple times?

2010-02-09 Thread Johann Spies
On 9 February 2010 21:14, Dmitri Zagidulin dzagidu...@gmail.com wrote: Several questions. Are you storing sessions on disk, or in a database? I do not clearly understand what you mean by storing sessions. I use sqlite as database. What's the decorator you're using, to require login? (is it

Re: [web2py] Re: Login mutliple times?

2010-02-09 Thread Johann Spies
I think I found the problem: it only happened when I accessed a html-page that was in /private/static. I want to have login access to that file but putting it in private/static caused this problem of double login. Somehow the session seems to disappear. Moving it to /static made the problem

[web2py] def data() - problem

2010-02-11 Thread Johann Spies
When I use the default/data/update on an unchanged existing record I get the following error: Traceback (most recent call last): File /home/www-data/web2py/gluon/restricted.py, line 173, in restricted exec ccode in environment File

Re: [web2py] Re: def data() - problem

2010-02-11 Thread Johann Spies
On 12 February 2010 08:06, mdipierro mdipie...@cs.depaul.edu wrote: what's the table definition? Your table seems to have a primary key field set to ' '. db.define_table(sarua, Field(title, text), Field(affiliation, text), Field(country),

[web2py] Re: [web2py:19827] Re: WSGI, Apache2, and web2py NOT at root

2010-02-13 Thread Johann Spies
On 15 April 2009 18:30, Mark Larsen larsen...@gmail.com wrote: I did figure out a hack if anyone comes up against this problem: RewriteEngine on RewriteRule ^/[NAMEOFAPP](.*)$ /web2py/[NAMEOFAPP]$1 [PT,L] WSGIScriptAlias /web2py /opt/web2py/wsgihandler.py This essentially allows you to

[web2py] Example of apache2 configuration where web2py exists along other sites

2010-02-13 Thread Johann Spies
I am becoming desperate about this problem. I could so far not succeed to get web2py working behind apache where web2py is not root (e.g. the setup of the ubuntu-setup script). Is there somewhere an working example of a setup where web2py is working with wsgi alongside a php site behind apache2?

Re: [web2py] Example of apache2 configuration where web2py exists along other sites

2010-02-16 Thread Johann Spies
Thanks to everybody who replied. I was in a situation where I urgently had to make an app available to a customer. In this case I had access to dns-entries so I just created a virtual IP on the server interface and created a separate domain name for that IP. I suppose I could just have used a

[web2py] crud.read()

2010-02-16 Thread Johann Spies
How do I use crud.read() without gettting the admin request session response buttons at the bottom? Or should I use SQLFORM with readonly fields? I have Regards Johann -- You received this message because you are subscribed to the Google Groups web2py-users group. To post to this group,

Re: [web2py] Re: crud.read()

2010-02-17 Thread Johann Spies
You get admin  request  session  response because you did not define a view so you have a generic one. You need a view Thanks. I could not understand that my view was ignored by web2py. After your email I checked again and found that I left out the 'default/' when I created it. Regards

[web2py] Building dynamic queries

2010-03-05 Thread Johann Spies
I have a form where the customer can type one keyword on each of the five fields (the first field may not be empty). From these keywords I have to build a query that would use .like('%' keyword'%') search in at least two fields in the database. I am trying something like this: k1 =

Re: [web2py] Re: web2py beautification

2010-03-12 Thread Johann Spies
On 11 March 2010 06:11, villas villa...@gmail.com wrote: Obviously if anyone else thinks they have an idea to move towards a well-tested div layout using a good naming scheme (preferably borrowed from a mainstream project which already has some templates) then do please mention it. I am only

Re: [web2py] Re: Building dynamic queries

2010-03-12 Thread Johann Spies
On 5 March 2010 23:03, Yarko Tymciurak resultsinsoftw...@gmail.com wrote: Does this seem dense to you?... If so, maybe this will make it readable: Thanks to both of you. I only started working recently in Python after a about 10 years of inactivity. This usage of 'reduce' is something new to

[web2py] Menu css

2010-03-16 Thread Johann Spies
I am struggling to find out exactly how the default web2py menu system uses the css. I want to change the background colour and the text colour of the menu. A pointer will be very helpful please. Regards Johann. -- Blessed are the poor in spirit: for theirs is the kingdom of

[web2py] Aligning subject fields using CRUD-display

2010-03-16 Thread Johann Spies
I have a model like this: db.define_table(policies_and_strategies, Field(country) , Field(policy_strategy_type) , Field(name_of_policy_strategy) , Field(brief_description_of_policy_strategy,text) ,

Re: [web2py] Re: Aligning subject fields using CRUD-display

2010-03-19 Thread Johann Spies
Thanks! Regards Johann -- Blessed are the poor in spirit: for theirs is the kingdom of heaven...Blessed are they which do hunger and thirst after righteousness: for they shall be filled...Blessed are the pure in heart: for they shall see God. Matthew

[web2py] How to handle subqueries?

2010-03-22 Thread Johann Spies
My client wants to be able to select from a list of records (SQLTABLE) which records to output in a csv-file (or pdf). Is this possible to do that using SQLTABLE? Regards Johann -- Blessed are the poor in spirit: for theirs is the kingdom of heaven...Blessed are they which do hunger

[web2py] Drop-down ticket

2010-03-27 Thread Johann Spies
The ticket: Traceback (most recent call last): File /home/js/web2py/gluon/restricted.py, line 173, in restricted exec ccode in environment File /home/js/web2py/applications/sadec/controllers/appadmin.py, line 418, in module File /home/js/web2py/gluon/globals.py, line 96, in lambda

[web2py] Local module problem

2010-04-03 Thread Johann Spies
I have this in my modules-file: def howmanyPages(total_found, items_per_page): if (total_found % items_per_page): pages = total_found / items_per_page else: pages = total_found / items_per_page -1 return(pages) def is_empty(u): if not u or u == :

Re: [web2py] Re: Local module problem

2010-04-03 Thread Johann Spies
On 3 April 2010 17:10, mdipierro mdipie...@cs.depaul.edu wrote: Because in the lambda is call somewhere inside web2py whete is_empty is not in the scope. db.policies_and_strategies.url.represent = lambda value: local.is_empty(value) == None  or A('url',_href=value) it is a python weirdness.

Re: [web2py] Re: Local module problem

2010-04-03 Thread Johann Spies
On 3 April 2010 17:10, mdipierro mdipie...@cs.depaul.edu wrote: Because in the lambda is call somewhere inside web2py whete is_empty is not in the scope. db.policies_and_strategies.url.represent = lambda value: local.is_empty(value) == None  or A('url',_href=value) it is a python

[web2py] Building a query from a form

2010-04-05 Thread Johann Spies
Using this form: veld = ['affiliation', 'country','year','journal','author'] form = SQLFORM.factory( Field('k', label='Type in up to 5 keywords separated by ' '(spaces).',requires=IS_NOT_EMPTY()), Field('how', label='Search all or any of the keywords',default='all', requires

Re: [web2py] Re: Building a query from a form

2010-04-05 Thread Johann Spies
Thanks. Johann -- Every good gift and every perfect gift is from above, and cometh down from the Father of lights, with whom is no variableness, neither shadow of turning. James 1:17 -- You received this message because you are subscribed to

Re: [web2py] Re: Building a query from a form

2010-04-05 Thread Johann Spies
query = query(db.sarua[request.vars.refine.lower()].like('%'+request.vars.value.lower+ '%')) TypeError: cannot concatenate 'str' and 'builtin_function_or_method' objects :( Regards Johann -- Every good gift and every perfect gift is from above, and cometh down from the Father

Re: [web2py] Re: Trouble starting web2py

2010-04-08 Thread Johann Spies
I have exactly the same problem on Debian after I upgraded several packages this morning. I suppose Debian installed an uncompatible simplejson. Any solution yet? if not path in sys.path: sys.path.insert(0,path) os.chdir(path) did not help for me either. Regards Johann -- Every

Re: [web2py] Re: How to handle subqueries?

2010-04-08 Thread Johann Spies
def csv():    import StringIO    s=StringIO.StringIO() db(db.mytable.id.belongs(session.records)).select().export_to_csv_field(s)    return s.getvalue() Thanks for your help. I could get the tickboxes working but not the csv-download. Only the headers were downloaded. In the end I am not

[web2py] csv download: how to do it

2010-04-10 Thread Johann Spies
I do not understand the code in the manual and what I have seen on this list about csv-downloads. I don't have a problem to do csv-export from the commandline in a shell. I just cannot figure out how the examples I referred to work in a MVC -environment. Take for example this export function

Re: [web2py] Re: csv download: how to do it

2010-04-10 Thread Johann Spies
I have this in my view: a href={{URL(r=request,f='csv',vars=dict(query=query))}} Download as csv-file /a And this controller: def csv(): import cStringIO s=cStringIO.StringIO() response.headers['Content-Type']='application/vnd.ms-excel'

Re: [web2py] Re: csv download: how to do it

2010-04-10 Thread Johann Spies
On 11 April 2010 00:38, mdipierro mdipie...@cs.depaul.edu wrote: One thing I see is that db(request.vars.query).select(db.sarua.All,limitby(1,250)).export_to_csv_file(s) should be db(request.vars.query).select(db.sarua.ALL,limitby=(0,250)).export_to_csv_file(s) Thanks. That was

Re: [web2py] Re: csv download: how to do it

2010-04-11 Thread Johann Spies
Thanks Thaddeus. I am not winning (yet)! I have now: def csv(): import cStringIO s=cStringIO.StringIO() import gluon.conttenttype query = request.vars.query if not query: return None else:

Re: [web2py] Re: csv download: how to do it

2010-04-11 Thread Johann Spies
With the help of firebug I determined that the problem was the link. I have changed the Controller to export the following: link=A('Download as csv',_href=URL(r=request,f='csv',args=query)) And that resulted in a Invalid request error. The url was:

[web2py] css-question: centering footer

2010-04-21 Thread Johann Spies
Can somebody explain to me why the following does not cause the copyright notice to be centered? div class=ez-box footer style=text-align: center; p Copyright © 2009 - Powered by a href=http://www.web2py.com;web2py/a /p /div Regards Johann --

Re: [web2py] css-question: centering footer

2010-04-21 Thread Johann Spies
Thanks Tim, You shouldn't need the p tags.  They only confuse the matter since you're doing direct formatting. That was actually the line in the default web2py layout.html. I removed the p and the text was centering ... Regards Johann -- Finally, brethren, whatsoever things are true,

Re: [web2py] How to change Web2py interface language

2010-04-22 Thread Johann Spies
On 22 April 2010 08:07, NoNoNo coldspring830...@gmail.com wrote: I want to change the interface language to English. According to some post, I change the language of Chrome browser to En, relaunched web2py and it didn't work. Can anyone help me out? I just added Afrikaans to a page. The name

[web2py] Web2py on Macbook

2010-04-24 Thread Johann Spies
I have two questions: one related to GAE and the other to Postgresql Coming from a Linux background I will in the next year or two use a Macbook Pro to develop web2py-stuff. I want to try out GAE but do not know how to get it going. According to the book the following should do it, but I get

Re: [web2py] Re: Web2py on Macbook

2010-04-24 Thread Johann Spies
On 24 April 2010 16:06, mdipierro mdipie...@cs.depaul.edu wrote: I use a Mac and I am not the only one on the list. All video tutorials on Vimeo are made with Mac. Including the one that explains how to deploy on GAE. Thanks. I will watch it and try again. To use postgresql you must install

Re: [web2py] Re: Web2py on Macbook

2010-04-24 Thread Johann Spies
On 24 April 2010 19:02, annet annet.verm...@gmail.com wrote: I have read this blog entry: http://blog.jonypawks.net/2008/06/20/installing-psycopg2-on-os-x/ I manually installed psycopg2 in Python's site-packages folder and that works without problem, unless of course I overlooked some risk.

Re: [web2py] Re: Web2py on Macbook

2010-04-24 Thread Johann Spies
On 24 April 2010 18:54, Julio ju...@techfuel.net wrote: Quick Question Johann, does it have to be all on the Mac? I mean, for instance, in my setup, I have a VM (Fusion) running ubuntu with a mere 512Mb RAM running on my iMac, I run web2py, psycopg2 and MySQL flawlessly and I use the Mac to

Re: [web2py] Re: Web2py on Macbook

2010-04-26 Thread Johann Spies
On 24 April 2010 16:06, mdipierro mdipie...@cs.depaul.edu wrote: I use a Mac and I am not the only one on the list. All video tutorials on Vimeo are made with Mac. Including the one that explains how to deploy on GAE. I have watched the video and made some progress but both on Linux and on my

[web2py] Custom validators and SQLForm

2010-04-26 Thread Johann Spies
The definition: db.define_table(navrae, Field(begindatum, date, default=None), Field(einddatum, date, default=None), Field(gebruiker, string, length=8, notnull=True, default='NULL'), Field(ipadres, string, length=15, notnull=True, default='NULL'), Field(datum_van_navraag,

Re: [web2py] Re: Custom validators and SQLForm

2010-04-28 Thread Johann Spies
Thanks Yarko, Hope this makes some sense now: At least that some darkness about what is happening in the background was cleared up - but I still do not understand enough to solve my problem. After you have digested this some,  have a look at

Re: [web2py] Re: Custom validators and SQLForm

2010-04-28 Thread Johann Spies
On 28 April 2010 13:42, Yarko Tymciurak resultsinsoftw...@gmail.com wrote: try using a debugger, and step thru to see what your values are, what you logic is doing...  you should find that helpful. You can use winpdb; or you can grab an evaluation copy of WindIDE (I find Wing easier to use) -

Re: [web2py] Re: Custom validators and SQLForm - apology

2010-04-28 Thread Johann Spies
Yarko, You can use winpdb; or you can grab an evaluation copy of WindIDE (I find Wing easier to use) - but either will work. Debugging normal python is not a problem to me, but I don't know how to debug Web2Py.  I don't use Windows and I don't know how to see the process you described in

Re: [web2py] Re: Custom validators and SQLForm - apology

2010-04-29 Thread Johann Spies
Working with winpdb was a good learning exercise which helped me to understand more about the way web2py does things. However, it did not help me to get an answer to my question about custom validators. I could not determine where and how the builtin validators come into play and how to add to

[web2py] Multiline labels for fields in SQLForm

2010-06-14 Thread Johann Spies
I would like to have multiline labels for fields in input forms. Is it possible to use SQLForm to produce that or should I do by hand using FORM? Regards Johann -- Finally, brethren, whatsoever things are true, whatsoever things are honest, whatsoever things are just, whatsoever things are

Re: [web2py] Re: Multiline labels for fields in SQLForm

2010-06-14 Thread Johann Spies
On 14 June 2010 14:17, mdipierro mdipie...@cs.depaul.edu wrote: label=SPAN('line1',BR(),'line2') Thanks! Johann -- Finally, brethren, whatsoever things are true, whatsoever things are honest, whatsoever things are just, whatsoever things are pure, whatsoever things are lovely, whatsoever

[web2py] Radio buttons and check boxes orientation

2010-06-16 Thread Johann Spies
How do I get radio buttons (and check boxes) to show up horizontally in stead of vertically? e.g. Yes {}No {} in stead of Yes {} No {} Regards Johann -- Finally, brethren, whatsoever things are true, whatsoever things are honest, whatsoever things are just, whatsoever things are

Re: [web2py] Re: Radio buttons and check boxes orientation

2010-06-16 Thread Johann Spies
On 16 June 2010 16:44, weheh richard_gor...@verizon.net wrote: Find out the id or class of the radio buttons. Use firebug to see, or look at the CSS Conventions section of the doc. You may need to resort to a custom form, but I doubt it. Then set the css attribute: display: inline; should

Re: [web2py] Re: Radio buttons and check boxes orientation

2010-06-18 Thread Johann Spies
Thanks MrFreeze and Hywang! Regards Johann -- Finally, brethren, whatsoever things are true, whatsoever things are honest, whatsoever things are just, whatsoever things are pure, whatsoever things are lovely, whatsoever things are of good report; if there be any virtue, and if there be any

[web2py] Forms partly filled with data from tables.

2010-06-25 Thread Johann Spies
I suppose I will have to find a way to combine SQLTable and SQLForm :) Example Table A: Surname | Name | School | someotherdata... a | b|c| ... d | e |f | ... These people attend courses. Another table (say B)

[web2py] A few questions about jqgrid

2010-07-05 Thread Johann Spies
I am a javascipt and jquery novice and would appreciate some information to help me understand how to use a jqgrid-plugin. My questions are overlapping in some cases. 1. How does jqgrid communicate with the backend database? 2. Do I have to put special mechanisms in place to make sure that

Re: [web2py] Re: A few questions about jqgrid

2010-07-05 Thread Johann Spies
On 6 July 2010 00:56, mdipierro mdipie...@cs.depaul.edu wrote: At this time jqgrid only communicates (via ajax) when you change page. The web2py plugin does not support in-place edit even if jqgrid does. You can find lots of examples in this app. This is a nice app developed by the book with

Re: [web2py] Re: is_in_set hoirzontal radio widget and is_empty as default

2010-07-08 Thread Johann Spies
On 1 July 2010 14:08, mdipierro mdipie...@cs.depaul.edu wrote: There isn't. Look at the code for the widget in gluon.sqlhtml.RadioWidget it should not be too difficult to allow multicolumn. It has been done for gluon.sqlhtml.CheckboxWidget I found a solution after a similar question in this

Re: [web2py] Re: Possible addition to IS_IN_DB

2010-07-09 Thread Johann Spies
I have a related query. On Jul 9, 12:35 am, David Marko dma...@tiscali.cz wrote: You can use full DAL query in IS_IN_DB validator e.g. IS_IN_DB(db(db.children.sex=='M'),'children.id','%(name)s' ) I want the result of IS_IN_DB to be part of my access control measures and dependent on who is

Re: [web2py] Re: Possible addition to IS_IN_DB

2010-07-09 Thread Johann Spies
You only use ajax if the option of field2 depend o selection for field1 and you always end up with usability problems when field1 and 2 are in the same form (because of the ajax delay). If the options depend on the logged in user it can be done without ajax. How depends on details.

[web2py] Help in getting csv-download to work

2010-07-10 Thread Johann Spies
I would appreciate help to get csv-download to work please. The following in my controller: def search_filled_in_forms(): sp = request.vars.sp form_id = request.vars.form_id.lower() title = request.vars.title.lower() date = request.vars.date query =

Re: [web2py] Re: Help in getting csv-download to work

2010-07-12 Thread Johann Spies
On 11 July 2010 00:32, mdipierro mdipie...@cs.depaul.edu wrote: I think a href={{=URL(r=request,f='evaluation_data.csv')}}Download as csv- file/a I still get NameError: name 'rows' is not defined I have also tried adding ,args=request.vars to the above url, but it made no difference. So

[web2py] csv: a showstopper for me. Is there another way?

2010-07-12 Thread Johann Spies
I could after several months not advance further than the animals example in the manual in using csv for downloads. Several questions and help from members on this list did not help me to achieve a single csv download in the following scenario: * user uses a form to define a selection *

  1   2   3   4   5   6   7   8   9   10   >