Received: from localhost.localdomain (postgresql.org [64.49.215.8]) by localhost (Postfix) with ESMTP id E910C475CFA for ; Thu, 9 May 2002 16:44:05 -0400 (EDT) Received: from pompom.freestart.hu (pompom.freestart.hu [213.197.64.6]) by postgresql.org (Postfix) with ESMTP id 77017475CEE for ; Thu, 9 May 2002 16:44:01 -0400 (EDT) Received: from line-69-39.dial.freestart.hu ([213.197.69.39] helo=there) by freestart.hu with smtp (Freestart relay 1 (FS-Lin)) id 175ul4-0000Vt-00; Thu, 09 May 2002 22:43:27 +0200 Content-Type: text/plain; charset="iso-8859-2" From: Papp Gyozo Reply-To: pgerzson@freestart.hu To: angelo.rigo@globo.com, pgsql-php@postgresql.org Subject: Re: Mailtos and links from a query result table! Date: Thu, 9 May 2002 22:43:17 +0200 X-Mailer: KMail [version 1.3.1] References: <3CD2936400024AD8@nplex.globo.com> In-Reply-To: <3CD2936400024AD8@nplex.globo.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-Id: X-Scanner: exiscan by Freestart X-Archive-Number: 200205/46 X-Sequence-Number: 1178 2002. május 9. 22:32 dátummal angelo.rigo@globo.com ezt írta: >Hi! >I need to make mailtos and hiperlinks in a query result table >i dont know wich variable to pass to the to make this > happen I suggest to you using named fields.You can achieve this by calling pg_fetch_array with PGSQL_ASSOC parameter (or pg_fetch_object()) $myrow = pg_fetch_array($result, $row, PGSQL_ASSOC); Then you can use $myrow['email'], etc, whatever you named those columns in postgres. > >my code below is not working! any idea? > >printf ("%s%s href='mailto:$myrow[19]'>%s href="$myrow[9]">%s%s%s >",$myrow[1], $myrow[2], $myrow[3], $myrow[19], $myrow[9], $myrow[10]); >$row++; >} >while ($row < $numrows); >printf (" >"); >pg_close($db); >?> > > > >________________________________________ >A busca mais veloz e precisa da internet. Acesse agora: > http://www.zoom.com.br. > > >---------------------------(end of > broadcast)--------------------------- TIP 4: Don't 'kill -9' the > postmaster -- Papp, Győző - pgerzson@freestart.hu