php-general Digest 21 Jul 2008 15:11:34 -0000 Issue 5581

2008-07-21 Thread php-general-digest-help
php-general Digest 21 Jul 2008 15:11:34 - Issue 5581 Topics (messages 277133 through 277144): Re: Pasword Protecting several pages 277133 by: Micah Gersten 277134 by: R.C. 277135 by: Micah Gersten Re: accessing variable value 277136 by: Chris syntax error

[PHP] syntax error

2008-07-21 Thread Ronald Wiplinger
On a system with php4 and mysql 4.x I had these lines: require(../db-config); // includes $dbhost, $buname, $dbpass $db = mysql_connect($dbhost, $dbuname, $dbpass); mysql_select_db($dbname,$db); $sql = SELECT * FROM CATEGORY WHERE .; $result = mysql_query($sql,$db);

Re: [PHP] syntax error

2008-07-21 Thread Ted Wood
Not a syntax error. It's not successfully connecting to the database. Check your settings. ~Ted On 21-Jul-08, at 4:24 AM, Ronald Wiplinger wrote: On a system with php4 and mysql 4.x I had these lines: require(../db-config); // includes $dbhost, $buname, $dbpass $db =

Re: [PHP] syntax error

2008-07-21 Thread Eric Butera
On Mon, Jul 21, 2008 at 7:24 AM, Ronald Wiplinger [EMAIL PROTECTED] wrote: On a system with php4 and mysql 4.x I had these lines: require(../db-config); // includes $dbhost, $buname, $dbpass $db = mysql_connect($dbhost, $dbuname, $dbpass); mysql_select_db($dbname,$db); $sql = SELECT

Re: [PHP] syntax error

2008-07-21 Thread Aschwin Wesselius
Eric Butera wrote: On Mon, Jul 21, 2008 at 7:24 AM, Ronald Wiplinger [EMAIL PROTECTED] wrote: On a system with php4 and mysql 4.x I had these lines: require(../db-config); // includes $dbhost, $buname, $dbpass $db = mysql_connect($dbhost, $dbuname, $dbpass);

Re: [PHP] syntax error

2008-07-21 Thread Eric Butera
On Mon, Jul 21, 2008 at 7:55 AM, Aschwin Wesselius [EMAIL PROTECTED] wrote: Eric Butera wrote: On Mon, Jul 21, 2008 at 7:24 AM, Ronald Wiplinger [EMAIL PROTECTED] wrote: On a system with php4 and mysql 4.x I had these lines: require(../db-config); // includes $dbhost, $buname, $dbpass

Re: [PHP] syntax error

2008-07-21 Thread Aschwin Wesselius
Eric Butera wrote: On Mon, Jul 21, 2008 at 7:55 AM, Aschwin Wesselius [EMAIL PROTECTED] wrote: Probably the mysql extension is not found or not loaded (due to not being compiled with the right path or the default path in PHP is not the right one). Happened to me a couple of times. --

Re: [PHP] syntax error

2008-07-21 Thread Eric Butera
On Mon, Jul 21, 2008 at 8:32 AM, Aschwin Wesselius [EMAIL PROTECTED] wrote: Oh my. I'm so sorry. You're absolutely right. I mixed these two. I'm a bit side-tracked today. Thanks for pointing that out. -- Aschwin Wesselius It's no problem, I got scared I was spreading propaganda!

Re: [PHP] session ok? [SOLVED]

2008-07-21 Thread tedd
Hi gang: I found the problem I was having with sessions and want to share it with you -- it surprised me. To refresh -- I was having a problem with destroying a session. I went through all the steps shown in the manual and dozens of recommended ways of doing it I found on the net.

Re: [PHP] session ok? [SOLVED]

2008-07-21 Thread Micah Gersten
When you use a header redirect, you start with a new page. Everything you did until then is gone. When you call session_start on the new page, it resumes the same session, not creates a new one. Thank you, Micah Gersten onShore Networks Internal Developer http://www.onshore.com tedd wrote:

Re: [PHP] session ok? [SOLVED]

2008-07-21 Thread Jason Pruim
On Jul 21, 2008, at 11:11 AM, tedd wrote: Hi gang: I found the problem I was having with sessions and want to share it with you -- it surprised me. To refresh -- I was having a problem with destroying a session. I went through all the steps shown in the manual and dozens of

Re: [PHP] session ok? [SOLVED]

2008-07-21 Thread Daniel Brown
On Mon, Jul 21, 2008 at 11:11 AM, tedd [EMAIL PROTECTED] wrote: That's the way it works PROVIDED that you do not use the following in your code: header('Location: http://www.yourdomain.com/whatever/index.php'); Was this line of code included in a script access at

Re: [PHP] Pasword Protecting several pages

2008-07-21 Thread tedd
At 7:44 PM -0700 7/20/08, R.C. wrote: No database, but just sessions? I looked at those and also Tedd was kind enough to send something but for some reason I can't get it to go. Can someone forward some good instructions on how to accomplish this task? I would greatly appreciate it. Still

Re: [PHP] session ok? [SOLVED]

2008-07-21 Thread tedd
At 11:23 AM -0400 7/21/08, Daniel Brown wrote: On Mon, Jul 21, 2008 at 11:11 AM, tedd [EMAIL PROTECTED] wrote: That's the way it works PROVIDED that you do not use the following in your code: header('Location: http://www.yourdomain.com/whatever/index.php'); Was this line of code

Re: [PHP] session ok? [SOLVED]

2008-07-21 Thread Andrew Ballard
On Mon, Jul 21, 2008 at 11:21 AM, Jason Pruim [EMAIL PROTECTED] wrote: On Jul 21, 2008, at 11:11 AM, tedd wrote: Hi gang: I found the problem I was having with sessions and want to share it with you -- it surprised me. To refresh -- I was having a problem with destroying a session. I went

Re: [PHP] session ok? [SOLVED]

2008-07-21 Thread Andrew Ballard
On Mon, Jul 21, 2008 at 11:37 AM, tedd [EMAIL PROTECTED] wrote: At 11:23 AM -0400 7/21/08, Daniel Brown wrote: On Mon, Jul 21, 2008 at 11:11 AM, tedd [EMAIL PROTECTED] wrote: That's the way it works PROVIDED that you do not use the following in your code: header('Location:

[PHP] PHP Warning: imagettftext()

2008-07-21 Thread Lou Baccari
Hello, I'm trying to move a site over to the V5 of CentOS and I having problems with php/gd/freetype. It looks like my older systems which is running php-4.3.8-1.1, gd-2.0.15-1, freetype-2.1.4-5 can execute the code successfully. Now when I try to execute the same code on CentOS V5 with

Re: [PHP] syntax error

2008-07-21 Thread Daniel Brown
On Mon, Jul 21, 2008 at 7:24 AM, Ronald Wiplinger [EMAIL PROTECTED] wrote: Try this: $result = mysql_query($sql,$db) or die(mysql_error()); -- /Daniel P. Brown Better prices on dedicated servers: Intel 2.4GHz/60GB/512MB/2TB $49.99/mo. Intel 3.06GHz/80GB/1GB/2TB $59.99/mo. Dedicated

Re: [PHP] syntax error

2008-07-21 Thread Daniel Brown
Please keep replies on list for all to benefit and be able to assist. On Mon, Jul 21, 2008 at 5:47 PM, Ronald Wiplinger [EMAIL PROTECTED] wrote: On Tue, Jul 22, 2008 at 1:51 AM, Daniel Brown [EMAIL PROTECTED] wrote: Try this: $result = mysql_query($sql,$db) or die(mysql_error());