Re: PHP button

From: Date: Mon, 26 Apr 2004 11:39:57 +0000
Subject: Re: PHP button
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-184620@lists.php.net to get a copy of this message
normally you just put this.form.submit in the onload="" of your input and your db will be updated this is html and javascript nothing to do with php "Brent Clark" <bclark@equation.co.za> a écrit dans le message news: 000901c42b81$eac7ba70$68b2a8c0@brent... > Hi all > > I have been for some time trying to get this right > > I need to diable a button, which I can do with javascript, all works fine > until the submit \ posting part . > > this is my part of my code below: > > This is my form section: > --------------------------- > <form action="scanbatch.php" method="POST" name="frm" > > > This is my php code, if the conditions are met: > ----------------------------------------------- > echo "<input type=\"button\" name=\"read\" value=\"Next\" > onclick=\"dob();\">"; > > This is my javascript: > ----------------------- > <script language="javascript"> > <!-- > function dob(){ > document.frm.read.disabled=true; > document.frm.submit(); > } > file://-> > </script> > > The button does disable the button like it should > the problem is that, apart from the disabling of the button, the does not > update my database. > In fact it does nothing > BUT > if I change the "type" from "button" to "submit" in the > <input> tag. > Then it works > I cant find away for this to work. (Co exist) > Could someone please help > I feel the problem defiantly lies with PHP > > Kind Regards and thanks in advance > Brent Clark

« previous php.general (#184620) next »