Received: from localhost (maia-3.hub.org [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 6E3F99FA136 for ; Sun, 3 Dec 2006 19:48:12 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-new, port 10024) with ESMTP id 01899-10 for ; Sun, 3 Dec 2006 19:48:03 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.4 Received: from nz-out-0102.google.com (nz-out-0506.google.com [64.233.162.228]) by postgresql.org (Postfix) with ESMTP id 760A29F9F8D for ; Sun, 3 Dec 2006 19:48:07 -0400 (AST) Received: by nz-out-0102.google.com with SMTP id i11so1709697nzh for ; Sun, 03 Dec 2006 15:48:06 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; b=GhVGuoKoObn5XvLDESCWBsJVeAeFRLjakVo+M1JuPzetU2GhieQ7GSLRR8ZL9gQvmORSgXtDSn1VhISjoWpy9HFc4WXJ4KfaYAcZmY6nFQtm7uDaT0YjekXdAqG0hBH3efyNj1xhWWy2rR5l9ddWicfTXGSWiuZUONhtiUBj9lY= Received: by 10.65.84.5 with SMTP id m5mr11755652qbl.1165189686009; Sun, 03 Dec 2006 15:48:06 -0800 (PST) Received: from ?10.1.1.11? ( [203.217.18.65]) by mx.google.com with ESMTP id q19sm33981469qbq.2006.12.03.15.48.03; Sun, 03 Dec 2006 15:48:05 -0800 (PST) Message-ID: <45736235.6080302@gmail.com> Date: Mon, 04 Dec 2006 10:48:05 +1100 From: Chris User-Agent: Thunderbird 1.5.0.8 (Windows/20061025) MIME-Version: 1.0 To: Mag Gam CC: Randy Moller , pgsql-php@postgresql.org Subject: Re: HTML FORMS selected question References: <457358D9.4000404@gmail.com> <20061203232352.A93629F9F8D@postgresql.org> <1cbd6f830612031543w26cdb6e2s82f1b958009d1b7@mail.gmail.com> In-Reply-To: <1cbd6f830612031543w26cdb6e2s82f1b958009d1b7@mail.gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200612/6 X-Sequence-Number: 3674 Mag Gam wrote: > Randy + Chris: > > Thx for the quick replies! > > Chris: > > $rows contain ip addresses (postgresql inet) type (example: 192.168.0.1 > ) > $options contain ip addresses (postgresql inet0 type (example: 127.0.0.1 > ) > (keep in mind) they are both arrays. $rows contact all ips, and $options > contact the ip addresses that were selected > > Randy: > I am not sure what you mean. The variables look right. I am getting no > errors! Just the logic is messed up. I think Randy's right. At the top you have: //The values that need to be selected $result_ip=pg_query($dbconn,$test_query); ^^^^^^^^^ but you are doing this: while ($row = pg_fetch_array($result)) { $result_ip at the top, $result in the second bit. If you don't see errors, turn up error reporting & display errors: error_reporting(E_ALL); ini_set('display_errors', true); Also that's not what I meant. I meant add a var_dump or print_r at each stage to see what you are *really* getting from the code. -- Postgresql & php tutorials http://www.designmagick.com/