Re: PHP Question

2008-05-06 Thread Salah Nait-Mouloud
Hi. try this ?php mysql_connect('localhost', 'login', 'password') or die('Could not connect: ' . mysql_error()); mysql_select_db(election) or die (Could not select election database); $result = mysql_query(update election set Votes = Votes + 1 where Name='TheGuy'); if (!$result) {

Re: PHP Question

2008-05-06 Thread Stut
On 6 May 2008, at 15:39, Michael Condon wrote: I have a PHP script that seems to be failing. I execute it using window.location.href(http://www.vote.com/vote2.php;): ?php $link = mysql_connect('localhost', 'login', 'password'); if (!$link) { die('Could not connect: ' . mysql_error()); }

RE: PHP Question

2008-05-06 Thread Jerry Schwartz
In general, if I have a PHP-generated page that produces a blank page, I execute the PHP code from the command line. It will probably fall over dead somewhere along the line, but you'll know if there are any syntax errors. Regards, Jerry Schwartz The Infoshop by Global Information Incorporated

Re: PHP Question

2008-05-06 Thread Darryle steplight
Hi Michael, Try placing the following at the top of your PHP code: ini_set('error_reporting', E_ALL | E_STRICT); ini_set('display_errors', 'On'); What error messages do you see on your page? On Tue, May 6, 2008 at 12:07 PM, Jerry Schwartz [EMAIL PROTECTED] wrote: In general, if I have a

RE: PHP Question

2002-04-11 Thread Andreas Frøsting
Hi, Ok so this really doesnt have anything to do with MySQL but I thought this might be a good placeto ask. Why? As you say, it's not in any way related to MySQL. reload the page and postthe message again! doh! Anyways, has anyone come up against a similar problem and found a way around

Re: PHP Question

2002-04-11 Thread BD
At 09:13 AM 4/11/2002, you wrote: Ok so this really doesnt have anything to do with MySQL but I thought this might be a good placeto ask. Ok heres the problem. I am constructing a Message Board with MySQL and php (was usingASP) and I dont want the user to reload/repost data. For example, say the