[web2py] Profile Page - auth()

2013-01-16 Thread Michael Gheith
ible. Any help would be much appreciated! Best, Michael Gheith --

[web2py] Star Rating

2013-02-08 Thread Michael Gheith
Hello web2py community :) I'm trying to implement a simple star rating for my site. I followed the steps in the web2py Application Development Cookbook, but it is not working unfortunately; I select 2 stars for example, but it's not being saved to the database. I have taken a look at the star

Re: [web2py] Star Rating

2013-02-09 Thread Michael Gheith
onse.flash = 'please fill out the form' return dict(form = form) It looks like the star rating value is not being sent from the form unfortunately because I get 'form has errors', 'value not allowed'. Any ideas? Best, Michael Gheith On Friday, February 8, 201

[web2py] Re: Star Rating

2013-02-09 Thread Michael Gheith
I printed the request.vars to the console, and this is what I got after form submission: So the star rating is definitely not making its way back to the server. I'm guessing it should look like the following: Please help :) Thanks, Michael Gheith On Friday, February 8, 2013 4:52:

[web2py] Re: Star Rating

2013-02-10 Thread Michael Gheith
Hello Alan, I added this code to the view and it is still not working. Can you post your working .w2p somewhere? It makes sense that the select field that represents that stars is somehow disabled. Hope to hear from you soon Alan! Best, M.G. On Sunday, February 10, 2013 8:12:49 AM UTC-6, Ala

[web2py] Re: Star Rating

2013-02-10 Thread Michael Gheith
ruary 8, 2013 4:52:19 PM UTC-6, Michael Gheith wrote: > > Hello web2py community :) > > I'm trying to implement a simple star rating for my site. I followed the > steps in the web2py Application Development Cookbook, but it is not working > unfortunately; I select 2 stars for

[web2py] Geolocation

2012-10-20 Thread Michael Gheith
Hello web2py community! I have a question: I know how to get the user's geolocation: if(navigator.geolocation) { navigator.geolocation.getCurrentPosition(printLocation); function printLocation(position) { alert("lat: " +position.coords.latitude + " lon: " + position.coor

[web2py] Re: Geolocation

2012-10-20 Thread Michael Gheith
> + "&b" + position.coords.longitude)}); > > > > On Saturday, 20 October 2012 17:42:15 UTC-5, Michael Gheith wrote: >> >> Hello web2py community! >> >> I have a question: >> >> I know how to get the user's geolocation: >> >

[web2py] [ login | register | lost password? ]

2011-11-15 Thread Michael Gheith
Does anyone know how to get rid of the brackets and pipes in: [ login | register | lost password? ] Also, would it be easy to append my own menu with the above? If so, then what file does this reside in? Thanks in advance, Michael Gheith

[web2py] Upload image and make a thumbnail question.

2013-08-04 Thread Michael Gheith
Hello web2py community! I used to be able to use the following web2py slice successfully in the past (about a year ago): http://www.web2pyslices.com/slice/show/1387/upload-image-and-make-a-thumbnail Now it's not working with the latest build of web2py. Is anyone able to successfully get this s

[web2py] Re: Upload image and make a thumbnail question.

2013-08-08 Thread Michael Gheith
jpg > > This was not enforded before. Please open a ticket about this and I will > make the * part optional.* > > On Sunday, 4 August 2013 18:13:02 UTC-5, Michael Gheith wrote: >> >> Hello web2py community! >> >> I used to be able to use the followi

[web2py] Re: {{=form.custom.widget.fieldname}} for Remember me checkbox

2013-11-21 Thread Michael Gheith
the form has been created. If you want just the checkbox > widget, you can do: > > {{=form.element('input#auth_user_remember')}} > > Anthony > > On Thursday, November 21, 2013 2:50:14 PM UTC-5, Michael Gheith wrote: >> >> My controller is: >> >> d

[web2py] {{=form.custom.widget.fieldname}} for Remember me checkbox

2013-11-21 Thread Michael Gheith
My controller is: def index(): return dict(form=auth.login()) I'm trying to customize the web2py login form in the view like the following: {{=form.custom.begin}} E-mail: {{=form.custom.widget.email}} Password: {{=form.custom.widget.password}} Login: {{=form.custom.submit}} {{=form.custom.

[web2py] Re: web2py Jobs and meetups

2013-12-18 Thread Michael Gheith
I would love to attend any and all meet ups in Chicago. web2py has been my bread and butter ever since I learned it :) On Tuesday, December 17, 2013 2:06:48 PM UTC-6, Massimo Di Pierro wrote: > > I am interested in knowing who are the web2py developers in Illinois and > in California (possibly

[web2py] Redirecting From Register Function

2014-01-07 Thread Michael Gheith
I have two different register forms in my application. One is pretty basic and I control where it redirects to using: auth.settings.register_next = URL('default', 'home') In my other register function I want to redirect it to a completely different place, and I want to send some vars over to th

[web2py] Apache ProxyPass to web2py

2014-04-08 Thread Michael Gheith
Hello web2py community! I have an Apache server that proxies all incoming requests of the nature x/y/z to my web2py application that is running on localhost using the Rocket web server. I did it with the following line: ProxyPass x/y/z http://localhost:8000/

[web2py] Re: Apache ProxyPass to web2py

2014-04-08 Thread Michael Gheith
> > On Tuesday, April 8, 2014 9:52:43 PM UTC+2, Michael Gheith wrote: >> >> Hello web2py community! >> >> I have an Apache server that proxies all incoming requests of the nature >> x/y/z to my web2py application that is running on localhost using the >&

[web2py] How to have app work with existing database?

2014-05-13 Thread 'Michael Gheith' via web2py-users
I have an existing Oracle database, it's pretty big. There are lots of tables and records in it. I want to create a new web2py application that will work with this existing database. Is there a way I can easily have a web2py app talk to this database, or do I have to manually specify all the

[web2py] Re: How to have app work with existing database?

2014-05-13 Thread 'Michael Gheith' via web2py-users
: > > You can use this script to auto-generate web2py models based on an > existing database: > https://github.com/web2py/web2py/blob/master/scripts/extract_oracle_models.py. > > Check the output, as it may not be perfect. > > Anthony > > On Tuesday, May 13, 2

[web2py] DAL Referencing By Name Not By ID Possible?

2014-05-27 Thread 'Michael Gheith' via web2py-users
I have two pretty basic tables: db.define_table('tiers', Field('name', 'string'), Field('created_on', 'datetime', default=request.now), format = '%(name)s') db.define_table('metrics', Field('tier_id', 'reference tiers'), Field('total_count', 'integer'), Field('total_size',

Re: [web2py] DAL Referencing By Name Not By ID Possible?

2014-05-28 Thread 'Michael Gheith' via web2py-users
tric = db(db.metrics.tier_name == 'name').select() > > or you can obviously write a helper function to short it > > get_metrics = lambda name: db(db.metrics.tier_name == name).select() > get_tier = lambda name: db(db.tier.name == name).select().first() > > tier =

[web2py] Re: DAL Referencing By Name Not By ID Possible?

2014-05-28 Thread 'Michael Gheith' via web2py-users
need to do > inserts programmatically outside of a form, you can just do a lookup in the > db.tiers table: > > tier_id = db.tiers(name='some name') > > Anthony > > On Tuesday, May 27, 2014 8:35:43 PM UTC-4, Michael Gheith wrote: >> >> I have two pr

[web2py] CRON Startup Script & DB Driver

2014-07-09 Thread 'Michael Gheith' via web2py-users
Hello web2py community! I created a shell script that essentially checks if web2py is running or not. Every hour CRON will run my script. If web2py is not running then it starts web2py from source with the following: export web2py_path=/Users/superman/desktop/web2py export port=8000 cd $web

[web2py] Re: CRON Startup Script & DB Driver

2014-07-09 Thread 'Michael Gheith' via web2py-users
It turns out that Cron didn't have access to cx_Oracle because it wasn't in the environment. Oops, should have checked that out first thing! On Wednesday, July 9, 2014 9:57:05 AM UTC-5, Michael Gheith wrote: > > Hello web2py community! > > I created a shell script that

[web2py] Re: routes_app

2014-07-21 Thread 'Michael Gheith' via web2py-users
This is a great example, but it focuses on the user coming from two different domains. Let's say for example that we wanted our app called app1, which is running on localhost with many other applications to be distinguishable. How would we modify the regular expression to handle that case? T

[web2py] Multiple Routes - Same App

2014-07-23 Thread 'Michael Gheith' via web2py-users
What I'm trying to do is to have my application serve 2 different customers via URLs like the following: http://127.0.0.1:8000/sam/client1//default/index http://127.0.0.1:8000/sam/client2//default/index My routes.py looks like: routes_in = ( ('/sam/client1/$a/$c/$f', '/$a/$c/$f

[web2py] Re: Multiple Routes - Same App

2014-07-24 Thread 'Michael Gheith' via web2py-users
0.1:8000/ <http://127.0.0.1:8000/sam/> > /default/index/client1 > http://127.0.0.1:8000/ <http://127.0.0.1:8000/sam/> > /default/index/client2 > > and have index pull request.args(0) to match to correct client > > On Thursday, July 24, 2014 12:41:29 AM UTC+8, Micha

[web2py] Re: Multiple Routes - Same App

2014-07-24 Thread &#x27;Michael Gheith' via web2py-users
d shift your function's logic outside > (into a module). > > > > On Thursday, July 24, 2014 11:50:28 PM UTC+8, Michael Gheith wrote: >> >> Hello lyn2py, >> >> Thank you for your response. Unfortunately it is necessary for me to >> have the URL prefix

[web2py] Re: Multiple Routes - Same App

2014-07-24 Thread &#x27;Michael Gheith' via web2py-users
de, in which case you might want to consider making sam > an app. > > > > On Friday, July 25, 2014 1:03:51 AM UTC+8, Michael Gheith wrote: >> >> That's a great idea lyn2py, but I expect to run multiple applications in >> one web2py instance. I can't hav

[web2py] Re: Multiple Routes - Same App

2014-07-29 Thread &#x27;Michael Gheith' via web2py-users
x27;), ('/b/$c/$f', > '/sam/client2/a/$c/$f') > > ) > > I would not recommend it. > > 2) if yes, you need to pass the clientX as args0: > > routes_in = [('/sam/$client/$a/$c/$f', '/$a/$c/$f/$client')] > routes_

[web2py] Re: Multiple Routes - Same App

2014-07-29 Thread &#x27;Michael Gheith' via web2py-users
x27;s still not producing the desired result unfortunately :( Further guidance would be much appreciated! Anthony, where are you on this one, I need your help man! Kindest of regards, Michael Joseph Gheith On Wednesday, July 23, 2014 11:41:29 AM UTC-5, Michael Gheith wrote: > > What I'm

[web2py] Re: Bare Login using API key

2014-07-30 Thread &#x27;Michael Gheith' via web2py-users
>From a high level view you can create an extra field in the auth table, and put random keys in it as a default value for each of your users. Or when someone signs up, they can automatically get assigned a random key using the DAL default parameter in Field. So each user will have a unique key

[web2py] Re: Multiple Routes - Same App

2014-08-02 Thread &#x27;Michael Gheith' via web2py-users
Is there way to programmatically set a path prefix in a controller rather than in routes.py? Best, Michael Joseph Gheith On Tuesday, July 29, 2014 4:47:17 PM UTC-5, Michael Gheith wrote: > > Hello, > > I rewrote what you had Massimo as the following (and it compiled just > fine)

[web2py] Oracle Database

2014-09-03 Thread &#x27;Michael Gheith' via web2py-users
I'm trying to create a new application that will talk with an existing Oracle database. In models.py I have the following: db.define_table('CONSUMED_FILE_STATUSES', Field('CONSUMED_FILE_STATUS', type='string', length=25), Field('CONSUMED_FILE_STATUS_DESC', type='string', length=4000),

[web2py] pg8000 unexpected EOF on client connection with an open transaction

2014-10-22 Thread &#x27;Michael Gheith' via web2py-users
Hello web2py community, I have a scheduled task that gets executed every 5 minutes by the web2py scheduler. It runs perfectly, no errors. The DBA has noticed the following message in the PostgreSQL logs every 5 minutes: unexpected EOF on client connection with an open transaction Any ideas w

[web2py] DB Driver Question

2014-11-19 Thread &#x27;Michael Gheith' via web2py-users
I have an application that is using a remote PostgreSQL database with the DAL. It's using the pg8000 driver which is in gluon>contrib. Now I recently installed a psycopg2 driver because I don't want to use pg8000 anymore. Is there a convenient way to find out what DB driver my application is

[web2py] Re: DB Driver Question

2014-11-19 Thread &#x27;Michael Gheith' via web2py-users
Is there is a way to specify which driver to use in the DAL connections string? DAL('postgres://:@:/') -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- Yo

[web2py] Re: Weird Error Message From Web2py - OSError: [Errno 24] Too many open files ???????

2015-03-08 Thread &#x27;Michael Gheith' via web2py-users
You could use the linux command lsof to see a list of open files. You can do something like the following to see what these open files are (if you care?): import subprocess data = subprocess.check_output(["lsof"]) lines = data.split("\n") for line in lines: print line On Sunday, February 2

[web2py] How do API keys work for authentication?

2017-02-22 Thread &#x27;Michael Gheith' via web2py-users
Let's pretend I want to create a service like Stripe. I know that if you make a call to a web service, you provided information (your api key) in the request header. Is this what JWT is used for? What's the workflow? Are there any examples out there? Does web2py support this type of authen

[web2py] Scheduler Question

2015-06-12 Thread &#x27;Michael Gheith' via web2py-users
I have an application that uses the scheduler. It runs really good, however I noticed odd behavior which I don't think is normal. When I launch a worker thread (just one) with the following everything works great: python web2py.py -K myapp A few days later I will come back to the node that th

[web2py] Re: Scheduler Question

2015-06-12 Thread &#x27;Michael Gheith' via web2py-users
log to see why another worker gets started. Each worker > started can result AT MOST as two processes, the worker itself and the > process that actually executes the task. > > On Friday, June 12, 2015 at 10:36:35 PM UTC+2, Michael Gheith wrote: >> >> I have an applicatio

[web2py] Re: Scheduler Question

2015-06-15 Thread &#x27;Michael Gheith' via web2py-users
I am querying a remote PostgreSQL database, and then inserting certain values into my local SQLite database, that's all... -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Re