[web2py] Re: SQLFORM.grid and export; some proposals

2013-05-23 Thread Nguyen Minh Tuan
Hi, I want to use export feature in SQLFORM.grid, but it doesn't work when query in self reference table. db.py : auth.settings.extra_fields['auth_user'] = [ Field('LineManager', 'reference auth_user'), . controller.py : lineMng = db.auth_user.with_alias('lineMng')

[web2py] Problems with parameter-based routing

2013-05-23 Thread Marian
I wanted to switch from pattern-based routing on a Windows IIS7 Server with isapi_wsgi to a parameter-based routing to benefit from nicer urls but it is not working. It either says invalid request or the server stucks in an endless loop. My functioning pattern based routing. As you can see I

[web2py] Re: Memory leak, SQLite, Windows (7, 2008)

2013-05-23 Thread Niphlod
Il giorno giovedì 23 maggio 2013 02:46:21 UTC+2, Simon Ashley ha scritto: Thanks Simone, A little more on this. Seems to to be an issue with windows consuming memory and grinding the system to semi halt. The characteristic isn't there in Linux. (ubuntu under vmware hosted by win7)

[web2py] request.get_vars

2013-05-23 Thread Domagoj Kovač
{{export_get_vars = request.get_vars}} {{export_get_vars.export_format = csv}} {{export_get_vars.export_format = xls}} {{=request.get_vars}} I have a code like this, i dont understand what is going on. I assign request.get_vars to export_get_vars, when i add seomething to

[web2py] Re: request.get_vars

2013-05-23 Thread David Marko
I think that request.get_vars return the reference to Storage object not its copy. So adding something to your variable de-facto adds items to former Storage. Dne čtvrtek, 23. května 2013 11:00:40 UTC+2 Domagoj Kovač napsal(a): {{export_get_vars = request.get_vars}}

[web2py] Making RSS feed auto-detectable?

2013-05-23 Thread Lamps902
I've added the following RSS feed function to my default controller: def updatefeed(): list_of_rss_entry_dicts = [ dict(title = data_set.f_headline, link = 'http://' + settings.domain_name, description =

[web2py] Re: request.get_vars

2013-05-23 Thread Anthony
This is how Python works. In Python, variable names act like labels that are attached to objects in memory. export_get_vars = request.get_vars export_get_vars is request.get_vars True id(request.get_vars) 54474840L id(export_get_vars) 54474840L As you can see above, export_get_vars and

[web2py] Re: Issues with rendering wiki in html.

2013-05-23 Thread villas
Hi Alan, On a general note (for future consideration), it is useful to have some records in markmin and others in html. To achieve this I think we really need to add a 'render_type' field to accompany the raw data. Then we can really mix it up. In one implementation, I also added an

[web2py] Twitter post function producing HTTP 401 error

2013-05-23 Thread Lamps902
I've added the Twitter posting function to my app, in the form in which it's presented in the book - http://www.web2py.com/books/default/chapter/29/14?search=twitter#Twitter-API. When calling this function with the username supplied in the Twitter Account menu's username field, my twitter

[web2py] Re: Twitter post function producing HTTP 401 error

2013-05-23 Thread Anthony
I think Twitter no longer supports basic authentication (we should probably update the book). Anthony On Thursday, May 23, 2013 9:03:54 AM UTC-4, Lamps902 wrote: I've added the Twitter posting function to my app, in the form in which it's presented in the book -

[web2py] show mandatory fields

2013-05-23 Thread Manuele Pesenti
Hello! I found this tricky way to have in evidence required fields in a grid defined like the following: code def dressMandatory(grid, table): Special representation for mandatory fields in grid for fieldname in table.fields: myid = '_'.join((table._tablename, fieldname, ))

[web2py] Re: Turning off SQL Logging

2013-05-23 Thread Massimo Di Pierro
No, but why? On Wednesday, 22 May 2013 23:16:20 UTC-5, Abhishek Gupta wrote: Hi, Is there an easy way to disable the logs generated in databases/sql.log other than editing gluon/dal.py? Regards Abhishek Gupta Co-founder, Zumbl -- --- You received this message because you are

Re: [web2py] Re: How to store data records for recurrent jQuery call

2013-05-23 Thread 冷春辉
Thank you Calvin and Alan. I'm not familiar with JSON and not much content in the book at the moment. I will do my research based on your suggestions. Regards, Lio On Wed, May 22, 2013 at 1:09 AM, Alan Etkin spame...@gmail.com wrote: You could then write some javascript to populate block 2

[web2py] Re: show mandatory fields

2013-05-23 Thread Manuele Pesenti
I beg your pardon... here it is the corrispondent solution for the form... but maybe you have better ideas def dressMandatoryInForm(form, *tabs): Special representation for mandatory fields in form tabs_fields = [[t[f] for f in t.fields if f != t._id.name] for t in tabs]

[web2py] Re: Turning off SQL Logging

2013-05-23 Thread Anthony
I believe sql.log only records the SQL for migrations (i.e., table creation, altering tables, and truncating tables), so logging will be disabled if you disable migrations. Anthony On Thursday, May 23, 2013 12:16:20 AM UTC-4, Abhishek Gupta wrote: Hi, Is there an easy way to disable the

[web2py] Re: Simple Postgres Exercise and ValueError: invalid literal for int() with base 10: 'SELECT'

2013-05-23 Thread ewong1111
The sql.log only said that the table was effectively created (it was), just couldn't read or write to it after. Are you using psycopg2? I was just using the pg8000 that comes with web2py, however someone informed me that web2py is broken as shipped (!) and sure enough, after installing

[web2py] Re: Twitter post function producing HTTP 401 error

2013-05-23 Thread Lamps902
Thanks, Anthony. Are you aware of any viable web2py solutions to making Twitter posts? Would it be a good idea just to use some python Twitter module? -- --- You received this message because you are subscribed to the Google Groups web2py-users group. To unsubscribe from this group and

[web2py] Re: rss feed

2013-05-23 Thread greaneym
Thank you, Massimo, After reading a lot more about feedparser and xlml, I began going through xlml examples but figured that feedparser was already doing most of what I needed, so I found this on stackoverflow,

[web2py] Re: Twitter post function producing HTTP 401 error

2013-05-23 Thread Anthony
I don't think web2py has anything built in, so just check the Twitter API docs and/or find an existing Python module to help. Anthony On Thursday, May 23, 2013 10:24:04 AM UTC-4, Lamps902 wrote: Thanks, Anthony. Are you aware of any viable web2py solutions to making Twitter posts? Would it

[web2py] Re: Twitter post function producing HTTP 401 error

2013-05-23 Thread Lamps902
Trying to get it running with this one: https://pypi.python.org/pypi/twitter. Thanks! On Thursday, May 23, 2013 9:58:34 AM UTC-5, Anthony wrote: I don't think web2py has anything built in, so just check the Twitter API docs and/or find an existing Python module to help. Anthony On

[web2py] Re: Turning off SQL Logging

2013-05-23 Thread Abhishek Gupta
Anthony, that souns good, thanks. Massimo, our sql.log grows to almost 1GB each day. I used fake_migrate=True for all the tables. Regards Abhishek Gupta Co-founder, Zumbl Zumbl http://zumbl.com | Facebookhttp://facebook.com/abhishekgupta.iitd | Twitter http://twitter.com/abhishekgupta92 |

Re: [web2py] Re: Testing your app using py.test

2013-05-23 Thread Arnon Marcus
On the contrary. I think information about testing using web2py, in conjuction with various testing-frameworks/tools, is highly relevant in the book, along with common testing-practices, and the way they apply when testing with web2py. The book, in that case, would act as an

Re: [web2py] Re: Testing your app using py.test

2013-05-23 Thread Arnon Marcus
On the contrary. I think information about testing using web2py, in conjuction with various testing-frameworks/tools, is highly relevant in the book, along with common testing-practices, and the way they apply when testing with web2py. The book, in that case, would act as an

[web2py] REF: Bare Ajax Login

2013-05-23 Thread Teddy Nyambe
Is there a way of using a pure Ajax request to web2py authentication and create a session for a successfully logged in user? -- ... Teddy Lubasi Nyambe Opensource Zambia Lusaka, ZAMBIA Cell: +260 97 7760473

Re: [web2py] Re: Testing your app using py.test

2013-05-23 Thread Arnon Marcus
On the contrary. I think information about testing using web2py, in conjuction with various testing-frameworks/tools, is highly relevant in the book, along with common testing-practices, and the way they apply when testing with web2py. The book, in that case, would act as an

Re: [web2py] Re: Testing your app using py.test

2013-05-23 Thread Arnon Marcus
On the contrary. I think information about testing using web2py, in conjuction with various testing-frameworks/tools, is highly relevant in the book, along with common testing-practices, and the way they apply when testing with web2py. The book, in that case, would act as an

Re: [web2py] Re: Testing your app using py.test

2013-05-23 Thread Arnon Marcus
On the contrary. I think information about testing using web2py, in conjuction with various testing-frameworks/tools, is highly relevant in the book, along with common testing-practices, and the way they apply when testing with web2py. The book, in that case, would act as an

Re: [web2py] Re: Testing your app using py.test

2013-05-23 Thread Arnon Marcus
On the contrary. I think information about testing using web2py, in conjuction with various testing-frameworks/tools, is highly relevant in the book, along with common testing-practices, and the way they apply when testing with web2py. The book, in that case, would act as an

[web2py] installing Pandas in site-packages

2013-05-23 Thread gthwang5
I am running into issues installing pandas (or any third-party module). Basically, my python on my windows machine sits on c:\python27\, and pandas is installed in c:\python27\Lib\Site-Packages\pandas Now, when I try to include pandas in my web2py app, however, I am getting an error saying

[web2py] How to force Auth module to disable Password encryption!

2013-05-23 Thread Ahmad Faiyaz
Hello, I am new on web2py. I am using it to develop a Programming Contest Management system. Now on a ONSITE Programming Contest , we have to distribute username and password printed on paper. So i have implemented a function which will generate user accounts automatically then print the

[web2py] Pandas installation

2013-05-23 Thread gthwang5
How do install Pandas on web2py? -- --- You received this message because you are subscribed to the Google Groups web2py-users group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit

[web2py] third party modules installation

2013-05-23 Thread gthwang5
Hi, I am currently hosting my site that I'm developing from my Windows 8 machine. I have my python installed in my computer at c:\python27\ and all the libraries get installed to c:\python27\site-packages I believe. According to the web2py doc, it says in order to use third party modules, I

[web2py] Re: Issues with rendering wiki in html.

2013-05-23 Thread Alan Etkin
On a general note (for future consideration), it is useful to have some records in markmin and others in html. To achieve this I think we really need to add a 'render_type' field to accompany the raw data. Then we can really mix it up. I have suggested the same here (without mixing

[web2py] Re: REF: Bare Ajax Login

2013-05-23 Thread Derek
You did read the book before you asked, yes? http://www.web2py.com/book/default/chapter/09#Access-Control-and-Basic-Authentication On Thursday, May 23, 2013 9:49:21 AM UTC-7, software.ted wrote: Is there a way of using a pure Ajax request to web2py authentication and create a session for a

[web2py] Re: Turning off SQL Logging

2013-05-23 Thread Anthony
Are you doing something that requires fake migrations every day (presumably multiple times per day)? Are the *.table files getting deleted? On Thursday, May 23, 2013 12:04:32 PM UTC-4, Abhishek Gupta wrote: Anthony, that souns good, thanks. Massimo, our sql.log grows to almost 1GB each day. I

[web2py] Re: Turning off SQL Logging

2013-05-23 Thread Abhishek Gupta
No, we aren't doing anything that requires fake_migrations to be true. I did it because of the peculiar needs that we had : Live Server - One domain - One database Dev Server - Multiple domains/web2py installations - Shared database Generally, when we make any change in db, I set migrate=True

Re: [web2py] Re: Testing your app using py.test

2013-05-23 Thread Anthony
We can update the book as frequently as we like. I think this is the place for announcements (there's also the Twitter feed). Aside from that, I suppose we could maintain some kind of framework roadmap document, but we don't really have a formal roadmap process, and I'm not sure there is a

[web2py] Re: installing Pandas in site-packages

2013-05-23 Thread Anthony
If you have Python installed on your machine and want web2py to use that version of Python, then simply download the source version of web2py and run that instead of using the Windows or Mac binaries. The binaries include their own standalone Python interpreter, so they won't see any modules

[web2py] Re: REF: Bare Ajax Login

2013-05-23 Thread Anthony
Basic authentication won't do anything with the session -- it requires sending the credentials on every request -- probably not what's desired here. Instead, the very next section in the book may help: http://www.web2py.com/book/default/chapter/09#Manual-Authentication. You can post the login

[web2py] Re: Turning off SQL Logging

2013-05-23 Thread Anthony
I was just wondering because I think writing to sql.log should only happen when there are actual changes to the table definitions (or if the *.table files are deleted or become corrupted). If you're not making any changes to the schema or touching the *.table files, I wouldn't think the sql.log

[web2py] Re: Turning off SQL Logging

2013-05-23 Thread Abhishek Gupta
No, .table files aren't deleted or corrupted. Most of the output are of the type timestamp: XXX ALTER TABLE YYY DROP COLUMN ZZZ; faked! Regards Abhishek Gupta Co-founder, Zumbl Zumbl http://zumbl.com | Facebookhttp://facebook.com/abhishekgupta.iitd | Twitter

[web2py] how to use library in web2py

2013-05-23 Thread Nam Soo In
I am trying to use library from http://grabz.it/api/python/ I put library in controller and module and import GrabzItClinet I basically copy the whole directory(GrabzIt) into controller and module The error says Cannot import module 'GrabzItClient' -- --- You received this message because

[web2py] Re: how to use library in web2py

2013-05-23 Thread Anthony
If you want to do: import GrabzItClient then it looks like you need to put these 4 fileshttps://code.google.com/p/grabzit/source/browse/#svn%2Ftrunk%2Fpython%2FGrabzItdirectly in the /yourapp/modules folder (don't put another sub-folder in that folder). Anthony On Thursday, May 23, 2013

[web2py] Redirect to another controller function with arguments from a callback function?

2013-05-23 Thread bracquet
In my views, I have: {{=A('click for more information', _href=URL(myCallback, args=[1]))}} When the anchor button is clicked, my callback will do some lookup and processing in the db, and then will redirect to a new page populated with the new information: def search_results(): resultSet

Re: [web2py] How to force Auth module to disable Password encryption!

2013-05-23 Thread Vinicius Assef
Using stadard web2py registration and authentication, you cannot disable it. You must write your own registration and authentication routines or change your workflow to register and print your cards. On Thu, May 23, 2013 at 5:44 AM, Ahmad Faiyaz faiya...@gmail.com wrote: Hello, I am new on

[web2py] Re: How to force Auth module to disable Password encryption!

2013-05-23 Thread Anthony
After auth.define_tables(), I think: db.auth_user.password.requires = None # or some other validator, such as IS_STRONG() should do it. By default, the password field has a CRYPT() validator, which does the hashing -- this would remove/replace that validator. However, this is not a good

[web2py] monitoring your web app

2013-05-23 Thread samuel bonilla
for web2py. http://newrelic.com/lp/python-monitoring?utm_source=REMKutm_medium=remarketingutm_content=rpmutm_campaign=RPMutm_term=graph250mpc=TA-REMK-RPM-EN-0-NewLP-textadgclid=COWghpP7rLcCFYWf4AodWlQAAA -- --- You received this message because you are subscribed to the Google Groups

[web2py] Re: Redirect to another controller function with arguments from a callback function?

2013-05-23 Thread Anthony
Why do you need to redirect at all? You can just call the search_results() function directly from the myButton() function: def search_results(resultSet): div = DIV(.) return dict(div=div) def myButton(): someId = request.args(0) resultSet = db() return

[web2py] Re: Redirect to another controller function with arguments from a callback function?

2013-05-23 Thread bracquet
search_results() will have to be exposed since I want to display the results on a different page (in search_results.html). I think returning the div using your suggestion would still be on the same page? On Thursday, May 23, 2013 3:38:17 PM UTC-4, Anthony wrote: Why do you need to redirect

[web2py] Postgres users beware auth.signature is_active; bad problem, easy to fix

2013-05-23 Thread Cliff Kachinske
auth.signature appends a boolean field called is_active to a table. The default is True. Under the covers it's not really boolean, it's char(1). When you insert a record, is_active is set to t. That's right, a lowercase t. Today I had the kind of problem where queries were missing records.

[web2py] Append() multiple components to html helper

2013-05-23 Thread Ian W. Scott
Is there a way to append multiple components to an HTML helper in a single append() call, or do we have to use a separate append() call for each component? I'm trying to append four components to a SPAN helper held in the variable wrapper. I've tried it this way:

[web2py] Re: Append() multiple components to html helper

2013-05-23 Thread Anthony
The .components attribute of the helper is a Python list, so you can use all the standard list methods, such as .extend(): wrapper.components.extend([new_component_1, new_component_2, new_component_3 , new_component_4]) Perhaps we should add an .extend() method directly to the helpers, as we

[web2py] dynamic dal query

2013-05-23 Thread António Ramos
hello i have 4 functions to do the same query. db(db.mytable1.id0).select() db(db.mytable2.id0).select() db(db.mytable3.id0).select() db(db.mytable4.id0).select() Maybe i can use only one like this def f1(table_to_query): row=db(db[table_to_query].id0).select() it does not work what is

[web2py] Re: Redirect to another controller function with arguments from a callback function?

2013-05-23 Thread Anthony
But presumably the myButton() function does not have its own view given that it was originally written to always redirect to another URL. In that case, why not just make the myButton.html view render the search results as desired? If you want a search_results.html view to be used from multiple

[web2py] Re: dynamic dal query

2013-05-23 Thread Anthony
That should work if you are passing in the name of the table as a string. If you're passing in the table object itself, then it should be: row=db(table_to_query.id0).select() As an aside, it helps if you report the error or traceback (or explain in more detail than does not work). Anthony

[web2py] Re: rss feed

2013-05-23 Thread greaneym
I figured out a solutiion. It may not be the most appropriate, though, in the controller, here is what gets returned: return(XML(t_conditions + t_summary)) and in the view, {{ =(XML(LOAD('default','weatherfeed')))}} This prints out the image and text with no extraneous characters. On

[web2py] BUG in JSON parsing in main.py

2013-05-23 Thread Matt
Hi there, I'm using Version 2.4.6-stable+timestamp.2013.05.17.14.52.19, Running on mac, Python 2.7.2, no external JSON library installed. Sending the following data via PUT, application/json; charset=UTF-8: {id: 3} results in a JSON parser error occurring at main.py: if is_json:

Re: [web2py] BUG in JSON parsing in main.py

2013-05-23 Thread Jonathan Lundell
On 23 May 2013, at 5:35 PM, Matt mjwat...@gmail.com wrote: Hi there, I'm using Version 2.4.6-stable+timestamp.2013.05.17.14.52.19, Running on mac, Python 2.7.2, no external JSON library installed. Sending the following data via PUT, application/json; charset=UTF-8: {id: 3} results

[web2py] Re: Referencing auth_user custom field in another table

2013-05-23 Thread Chris Teodorski
Anthony, How do I set them to writable when I need them to be? I'm attempting to update them in a controller and I'm not sure how to do it Chris On Monday, 20 May 2013 12:19:32 UTC-4, Anthony wrote: Setting a field's writable attribute to False prevents users from inputting values in

[web2py] Re: Referencing auth_user custom field in another table

2013-05-23 Thread Chris Teodorski
So I'm stuck again and once again -- appreciate any help. What I'm doing it pretty simple, I think. The code runs fine -- no error messages, but the field isn't updated as I expect. So something is borked. flag contains an integer from 1-16. The field in the db is called f_chal1, f_chal2,

Re: [web2py] Re: How to force Auth module to disable Password encryption!

2013-05-23 Thread Vinicius Assef
Good point, Anthony. I didn't remember the password was encrypted in a validator. Shame on me, guys. ;-) On Thu, May 23, 2013 at 4:29 PM, Anthony abasta...@gmail.com wrote: After auth.define_tables(), I think: db.auth_user.password.requires = None # or some other validator, such as

[web2py] Re: Referencing auth_user custom field in another table

2013-05-23 Thread Anthony
auth.user.challenge.writable=True First, you're working with the wrong object there. auth.user is just a Row object holding the db.auth_user record of the current logged in user. It's keys/attributes hold values, not DAL Fields -- so it doesn't make sense to set writable

Re: [web2py] BUG in JSON parsing in main.py

2013-05-23 Thread Matt
Thanks for your response. Unfortunately that example isn't quite the same as how json is processed from the body in main.py. I.e. it's using cStringIO I think. I can put together an example that highlights this I guess. On Friday, May 24, 2013 12:53:14 PM UTC+12, Jonathan Lundell wrote: On

Re: [web2py] BUG in JSON parsing in main.py

2013-05-23 Thread Jonathan Lundell
On 23 May 2013, at 7:52 PM, Matt mjwat...@gmail.com wrote: Thanks for your response. Unfortunately that example isn't quite the same as how json is processed from the body in main.py. I.e. it's using cStringIO I think. Right. That's why I think it'd be useful to see what body.read()

[web2py] Re: third party modules installation

2013-05-23 Thread Massimo Di Pierro
This is fine. Just use the web2py source distribution, not the web2py windows binary. On Wednesday, 22 May 2013 22:31:37 UTC-5, gthwang5 wrote: Hi, I am currently hosting my site that I'm developing from my Windows 8 machine. I have my python installed in my computer at c:\python27\

[web2py] Re: Pandas installation

2013-05-23 Thread Massimo Di Pierro
Install python source and install the pandas libraries as you normally would (pip., easy_install) On Wednesday, 22 May 2013 22:55:22 UTC-5, gthwang5 wrote: How do install Pandas on web2py? -- --- You received this message because you are subscribed to the Google Groups web2py-users group.

[web2py] Re: Issues with rendering wiki in html.

2013-05-23 Thread Massimo Di Pierro
I think you submitted a patch one. Do you stil have it? On Thursday, 23 May 2013 12:28:06 UTC-5, Alan Etkin wrote: On a general note (for future consideration), it is useful to have some records in markmin and others in html. To achieve this I think we really need to add a 'render_type'

[web2py] Re: Postgres users beware auth.signature is_active; bad problem, easy to fix

2013-05-23 Thread Massimo Di Pierro
This is a backward compatibility issues. The fact that it inserts a 't' instead of a 'T' is more of a concern to me. How was the query built? The source clearly says: TRUE = 'T' FALSE = 'F' On Thursday, 23 May 2013 16:21:18 UTC-5, Cliff Kachinske wrote: auth.signature appends a boolean

[web2py] Re: BUG in JSON parsing in main.py

2013-05-23 Thread Massimo Di Pierro
Please open a ticket about this. On Thursday, 23 May 2013 19:35:08 UTC-5, Matt wrote: Hi there, I'm using Version 2.4.6-stable+timestamp.2013.05.17.14.52.19, Running on mac, Python 2.7.2, no external JSON library installed. Sending the following data via PUT, application/json;

[web2py] Mismatch between code in tickets and controller

2013-05-23 Thread Alex Heyden
I've been using Web2Py successfully for this project since about September. Recently, I restarted the server because something in the process had my CPU pegged to 100%. Since then, I've been unable to update my controller file. I normally upload my updated code to the server and run a script to

Re: [web2py] Re: REF: Bare Ajax Login

2013-05-23 Thread Teddy Nyambe
Of course read the book, auth.login_bare() manages my sessions automatically? Will check it out thanx On 23 May 2013 20:09, Anthony abasta...@gmail.com wrote: Basic authentication won't do anything with the session -- it requires sending the credentials on every request -- probably not what's

Re: [web2py] Re: REF: Bare Ajax Login

2013-05-23 Thread Teddy Nyambe
Why I asked cause a 2 months or so Massimo contributed to a similar thread and this is what he wrote: Should we offer something like {{=auth.ajax_login()}} helper which submits to /user/login? If would not be difficult to write. How should it work? The guy who hd asked a question on pure Ajax

Re: [web2py] Re: REF: Bare Ajax Login

2013-05-23 Thread Teddy Nyambe
In addition, auth.login_bare() seems to check only with auth_user table, if my authentication is based on LDAP it may not work. Any progress that has been made on auth.ajax_login()? On 24 May 2013 05:58, Teddy Nyambe software@gmail.com wrote: Why I asked cause a 2 months or so Massimo

[web2py] handle request.args string value contain a space

2013-05-23 Thread 黄祥
hi folks, is there anyone know how to handle request.args string value contain a space? e.g. models/menu.py if request.controller=='default': response.menu = [ (T('Home'), False, URL('default', 'index'), []), ] services = db(db.service).select(orderby=db.service.id)

[web2py] Re: BUG in JSON parsing in main.py

2013-05-23 Thread Matt
Have figured it out now. I'm using the restful decorator to expose some web services. In the example given in the book it shows: @request.restful() def api(): response.view = 'generic.json' def GET(tablename,id): if not tablename=='person': raise HTTP(400) return

[web2py] how to link a custom form to a python method

2013-05-23 Thread gthwang5
Hi, I am a complete web2py noob, so sorry in advance for a potentially dumb question. *I am trying to create a simple form that has three fields. StartDate, EndDate, Symbol* When I click submit button, I have a python function that - takes these three variables - creates a table (