RE: [PHP-DB] Value of $_POST['submit']
When I'm developing a number of pages and don't keep track of every variable or form name (etc), I plant a print_r($_POST); at the top of the page, so there's no guessing what gets sent to the page . . . If you have an empty $_POST array, then the form isn't using action=post, or you didn't code your button as type=submit (?) Just suggestions - since I can't see the code. Steve - Original Message - From: Ron Piggott [EMAIL PROTECTED] To: PHP DB php-db@lists.php.net Sent: Thursday, November 27, 2008 7:02 PM Subject: [PHP-DB] Value of $_POST['submit'] I am working on the following web page tonight: http://www.actsministrieschristianevangelism.org/verseoftheday/ I am trying to program the Load Previous Issue Random Issue and Load Next Issue buttons. I am using Ajax to pass the date the user is requesting to the PHP script for processing. I am wondering how my PHP script may access the value of value of $_POST['submit']. At present echo $_POST['submit']; doesn't give me a value. Consequently all queries to the mySQL database fail. Ron -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Saving Data to a csv file
Hi, I'm trying to make a downloadable csv file from a address database based on PHP and MySQL. I have a script for getting the data (no problem so far) but I want to have the data delivered as a starting downlaod in csv format. Can anyone give me a helping hand? Thx in advance Lensman -- DSL Komplett von GMX +++ Supergünstig und stressfrei einsteigen! AKTION Kein Einrichtungspreis nutzen: http://www.gmx.net/de/go/dsl -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] SESSIONS
And also use $_POST[SUBMIT] or set register_globals On You need to register you varible first with the session -Original Message- From: David Rice [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 25, 2003 3:10 PM To: [EMAIL PROTECTED] Subject: [PHP-DB] SESSIONS Here's something i can't get working it won't go to the last clause of this page i don't think it can set the session variable anyone see what im doing wrong? i need more caffeine to get my brain fired up today lol.. === ? session_start();? HTML head /head body ? if ( !$SUBMIT ){ ? form action=? echo $PHP_SELF; ? method=post name=TEST input name=name type=text value=name size=20 maxlength=20 input name=SUBMIT type=submit value=SUBMIT /form ? } elseif($SUBMIT){ $_SESSION[name] = $HTTP_POST_VARS[name]; ? a href=? echo $PHP_SELF; ? next /a ? } elseif( ( $SUBMIT ) ( isset ( $_SESSION[name] ) ) ) { echo $_SESSION[name]; } ? /body /HTML _ Stay in touch with absent friends - get MSN Messenger http://messenger.msn.co.uk -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Storing IP into DB
Hi, I wondered if anyone could help me. I would like to store the user IP only once per multiple visits. The code below store the user IP on every visit which is not my intention. Please I would like to have the IP stored at once upon repetitive visits of the user. Thank Below is my code ? $ip_address = getenv (REMOTE_ADDR); $the_date = date(Y-m-D); $connect = mysql_connect(localhost, user, pass) or die(Cant Connect!); mysql_select_db(ipvisits)or die(Cant Connect To Database); mysql_query(INSERT into visitorsips (ip, date) VALUES ('$ip_address', '$the_date')); mysql_close($connect); ? - Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now
[PHP-DB] Storing IP into DB
Hi, I wondered if anyone could help me. I would like to store the user IP only once per multiple visits. The code below store the user IP on every visit which is not my intention. Please I would like to have the IP stored at once upon repetitive visits of the user. Thank Below is my code ? $ip_address = getenv (REMOTE_ADDR); $the_date = date(Y-m-D); $connect = mysql_connect(localhost, user, pass) or die(Cant Connect!); mysql_select_db(ipvisits)or die(Cant Connect To Database); mysql_query(INSERT into visitorsips (ip, date) VALUES ('$ip_address', '$the_date')); mysql_close($connect); ? - Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now
[PHP-DB] Connecting to Mysql Server
Hi, How can I change the default connecting port using php script. Thanks - Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now
[PHP-DB] Basic HTTP authentication
hi GUys Please this may sound too elementary but I need your help. How can I configure apache httpd.con file in order to support the use of Basic HTTP authentication. I am using apache 1.3.26 on windows. Thanks - Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now
[PHP-DB] Basic HTTP authentication
hi GUys Please this may sound too elementary but I need your help. How can I configure apache httpd.con file in order to support the use of Basic HTTP authentication. I am using apache 1.3.26 on windows. Thanks - Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now
[PHP-DB] using Flat File
Hi, I have posted my question to this list before but I did not get a help that I was expected. All I wanted to do is to give access for the users to view a page in which the below code is embedded. The user will enter his/her username and password. But the code is not working. I don't know what to think. I need your help guys. Don't let me die on this code ?php $auth = false; if (isset( $PHP_AUTH_USER ) isset($PHP_AUTH_PW)) { $filename = 'c:\\php_data\\file.txt'; $f = @fopen($filename, r); if ($f != FALSE) {$a = @fread($f, filesize($filename)); fclose($f); } else { echo Could not open file; } $lines = explode ( \n, $file_contents ); foreach ( $lines as $line ) { list( $username, $password ) = explode( ':', $line ); if ( ( $username == $PHP_AUTH_USER ) amp;amp; ( $password == $PHP_AUTH_PW ) ) { $auth = true; break; } } } if ( ! $auth ) { header( 'WWW-Authenticate: Basic realm=Private' ); header( 'HTTP/1.0 401 Unauthorized' ); echo 'Authorization Required.'; exit; } else { echo 'PYou are authorized!/P'; } ? - Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now
[PHP-DB] using Flat File
Hi Guys, i wondered if there any assistance you could do for me on this code. I have called on God many times to assist me but He did not respond. I hope you would. What I am trying to do is to allow certain users to view a certain page . I stored their names and passwords in a file.txt But the is not working is there any help?? ?php $auth = false; if (isset( $PHP_AUTH_USER ) amp;amp; isset($PHP_AUTH_PW)) { $filename = 'c:\\php_data\\file.txt'; $f = @fopen($filename, r); if ($f != FALSE) {$a = @fread($f, filesize($filename)); fclose($f); } else { echo Could not open file; } $lines = explode ( \n, $file_contents ); foreach ( $lines as $line ) { list( $username, $password ) = explode( ':', $line ); if ( ( $username == $PHP_AUTH_USER ) amp;amp; ( $password == $PHP_AUTH_PW ) ) { $auth = true; break; } } } if ( ! $auth ) { header( 'WWW-Authenticate: Basic realm=Private' ); header( 'HTTP/1.0 401 Unauthorized' ); echo 'Authorization Required.'; exit; } else { echo 'PYou are authorized!/P'; } ? - Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now
[PHP-DB] interbase
Hi, I tried to connect to remote Interbase server. There is a result below: Warning: InterBase: Unable to complete network request to host "192.168.1.10". Failed to locate host machine. Undefined service gds_db/tcp. in ... File services on remote Interbase server contains: gds_db3050/tcp Could you help me to resolve this problem? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]