Lists: | pgsql-php |
---|
From: | Thom Dyson <TDyson(at)sybex(dot)com> |
---|---|
To: | pgsql-php(at)postgresql(dot)org |
Subject: | Queries that return permissions |
Date: | 2004-02-13 17:51:36 |
Message-ID: | OF733211D3.38B30848-ON88256E39.0061C538-88256E39.00621BC1@sybex.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-php |
I'm laying the ground work to migrate a database to a web front end. One
thing I would like is, when generating the HTML, to display read-only
fields as text, while fields that are updateable as input fields, based on
the permissions that the user has to the table. This way a given user
would not be confused trying to change data they have no permission to.
Does anyone know where there is code that will do this sort of thing?
Thom Dyson
Director of Information Services
Sybex, Inc.
From: | Joe Conway <mail(at)joeconway(dot)com> |
---|---|
To: | Thom Dyson <TDyson(at)sybex(dot)com> |
Cc: | pgsql-php(at)postgresql(dot)org |
Subject: | Re: Queries that return permissions |
Date: | 2004-02-13 18:15:05 |
Message-ID: | 402D1429.2050908@joeconway.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-php |
Thom Dyson wrote:
> the permissions that the user has to the table.
> Does anyone know where there is code that will do this sort of thing?
See:
http://www.postgresql.org/docs/current/static/functions-misc.html#FUNCTIONS-MISC-ACCESS-TABLE
HTH,
Joe
From: | Thom Dyson <TDyson(at)sybex(dot)com> |
---|---|
To: | Joe Conway <mail(at)joeconway(dot)com> |
Cc: | pgsql-php(at)postgresql(dot)org |
Subject: | Re: Queries that return permissions |
Date: | 2004-02-13 18:19:49 |
Message-ID: | OF9ECC1C82.180F27F7-ON88256E39.0064A820-88256E39.0064B158@sybex.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-php |
Oops, Not running 7.4 yet. Maybe I should upgrade :)
Thom Dyson
Director of Information Services
Sybex, Inc.
Joe Conway <mail(at)joeconway(dot)com> wrote on 02/13/2004 10:15:05 AM:
> Thom Dyson wrote:
> > the permissions that the user has to the table.
> > Does anyone know where there is code that will do this sort of thing?
> See:
> http://www.postgresql.org/docs/current/static/functions-misc.
> html#FUNCTIONS-MISC-ACCESS-TABLE
> HTH,
> Joe
From: | Thom Dyson <TDyson(at)sybex(dot)com> |
---|---|
To: | Joe Conway <mail(at)joeconway(dot)com> |
Cc: | pgsql-php(at)postgresql(dot)org |
Subject: | Re: Queries that return permissions - D'OH |
Date: | 2004-02-13 18:21:52 |
Message-ID: | OF12E31863.699D4D34-ON88256E39.0064D3A5-88256E39.0064E10E@sybex.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-php |
Oh MAN. I NEED more coffee. 7.3 has this.
Thom Dyson
Director of Information Services
Sybex, Inc.
Joe Conway
<mail(at)joeconway(dot)c
om> To
Sent by: Thom Dyson <TDyson(at)sybex(dot)com>
pgsql-php-owner(at)p cc
ostgresql.org pgsql-php(at)postgresql(dot)org
Subject
Re: [PHP] Queries that return
02/13/2004 10:15 permissions
AM
Thom Dyson wrote:
> the permissions that the user has to the table.
> Does anyone know where there is code that will do this sort of thing?
See:
http://www.postgresql.org/docs/current/static/functions-misc.html#FUNCTIONS-MISC-ACCESS-TABLE
HTH,
Joe
---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)
From: | Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au> |
---|---|
To: | Thom Dyson <TDyson(at)sybex(dot)com> |
Cc: | pgsql-php(at)postgresql(dot)org |
Subject: | Re: Queries that return permissions |
Date: | 2004-02-14 04:13:01 |
Message-ID: | 402DA04D.3080703@familyhealth.com.au |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Lists: | pgsql-php |
Hi Thom,
Download phpPgAdmin (phppgadmin.sourceforge.net) and look at the
getPrivileges function in classes/database/Postgres.php.
Cheers,
Chris
Thom Dyson wrote:
>
>
>
> I'm laying the ground work to migrate a database to a web front end. One
> thing I would like is, when generating the HTML, to display read-only
> fields as text, while fields that are updateable as input fields, based on
> the permissions that the user has to the table. This way a given user
> would not be confused trying to change data they have no permission to.
>
> Does anyone know where there is code that will do this sort of thing?
>
> Thom Dyson
> Director of Information Services
> Sybex, Inc.
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 9: the planner will ignore your desire to choose an index scan if your
> joining column's datatypes do not match