X-Original-To: pgsql-php-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.193]) by svr1.postgresql.org (Postfix) with ESMTP id 8914B310AA5 for ; Mon, 30 Jun 2003 21:35:11 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (svr1.postgresql.org [64.117.224.193]) (amavisd-new, port 10024) with ESMTP id 84534-09 for ; Mon, 30 Jun 2003 18:35:01 -0300 (ADT) Received: from mail.zoidtechnologies.com (pcp01923808pcs.canton01.mi.comcast.net [68.43.20.6]) by svr1.postgresql.org (Postfix) with ESMTP id 165953107B8 for ; Mon, 30 Jun 2003 18:35:01 -0300 (ADT) Received: by mail.zoidtechnologies.com (Postfix, from userid 500) id 289B5C1930; Mon, 30 Jun 2003 17:35:01 -0400 (EDT) Date: Mon, 30 Jun 2003 17:35:01 -0400 From: Jeff To: Michael Hanna Cc: pgsql-php@postgresql.org, Jeff Subject: Re: Best way to convert PG's TIMESTAMPTZ to PHP DATE? Message-ID: <20030630213501.GG1614@zoidtechnologies.com> References: <20030630212701.GF1614@zoidtechnologies.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030630212701.GF1614@zoidtechnologies.com> User-Agent: Mutt/1.4.1i X-Archive-Number: 200306/43 X-Sequence-Number: 2107 On Mon, Jun 30, 2003 at 05:27:01PM -0400, Jeff wrote: [..snipped..] > $lastmodified = $row["datepostedepoch"]; > $lastmodified = datestamp($lastmodified); > print "{$lastmodified}"; [..snipped..] EEK! I should have proofread the *entire* message :( that really should read: $dateposted = $row["datepostedepoch"]; $dateposted = datestamp($dateposted); print "{$dateposted}"; obviously that doesn't cover loading $row with the right values, but eros handles that, too, for the most part. there are working examples in the tarball of this technique in action. regards, Jeff -- || Jeff - http://zoidtechnologies.com/ || GNUPG Fingerprint: A607 0F19 7C75 1305 67E4 BDFF 26BD 606E 3517 2A42