Re: [PHP] neubie seeking answers

2011-03-31 Thread Kirk Bailey
PERFECT SIMPLE SOLUTION. THANK YOU! On 3/31/2011 12:34 PM, Stuart Dallas wrote: On Thursday, 31 March 2011 at 17:24, Kirk Bailey wrote: I need to extract the name of the subdirectory a page lives in to use in the title for that page. This will be returned as a string to echo to the output strea

[PHP] Re: If Statements Array and Notice Undefined Index

2011-03-31 Thread Al
On 3/31/2011 10:45 AM, Nicholas Cooper wrote: Good day, I have three arrays A, B and C. Anyone of them might not have the 'id' key set which will give the Notice "Undefined index: id". I just wanted to know what the correct approach to this problem would be; without making the code overly com

Re: [PHP] Sessions - More Info

2011-03-31 Thread Boers Steven
Dear List - Thank you for your help in the past. This an update on my session problems. Here is a simple test program. It never increments the session counter; ie, does not detect that $_SESSION has been set. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";> http://www.w3.o

Re: [PHP] Closing Session

2011-03-31 Thread Ethan Rosenberg
127.0.0.1 localhost development subdomain.development Don't worry about it being an FQDN. Prior to checking with the router or DNS servers, all modern systems check the hosts file. Then just add a reference to each in your Apache configuration file and restart Apache. Boom. Don

Re: [PHP] Closing Session

2011-03-31 Thread Ethan Rosenberg
At 05:37 PM 3/31/2011, Ethan Rosenberg wrote: At 04:51 PM 3/31/2011, Daniel Brown wrote: On Thu, Mar 31, 2011 at 16:40, Ethan Rosenberg wrote: > > > Ash - > > I can be working on more than one program simultaneously and have one tab > open w/ program A and another w/ program B. The si

[PHP] PHP 5.2.x with MySQL 5.5.x

2011-03-31 Thread Andre Matos
Hello, We are migrating our MySQL database from 5.0.x to 5.5.x and I have noticed that the current PHP 4.4.x we have will not be compatible with the MySQL 5.5.x.. It has the Client API version for MySQL 5.0.x Unfortunately at this point, we cannot use PHP 5.3.x because of some old application

Re: [PHP] Closing Session

2011-03-31 Thread Stuart Dallas
On Thursday, 31 March 2011 at 21:53, Ashley Sheridan wrote: On Thu, 2011-03-31 at 16:40 -0400, Ethan Rosenberg wrote: > > > At 02:12 PM 3/31/2011, Ashley Sheridan wrote: > > > On Thu, 2011-03-31 at 13:54 -0400, Ethan Rosenberg wrote: > > > > > > > At 01:30 PM 3/31/2011, Daniel Brown wrote: > > >

Re: [PHP] Closing Session

2011-03-31 Thread Steve Staples
On Thu, 2011-03-31 at 16:51 -0400, Daniel Brown wrote: > On Thu, Mar 31, 2011 at 16:40, Ethan Rosenberg wrote: > > > > > > Ash - > > > > I can be working on more than one program simultaneously and have one tab > > open w/ program A and another w/ program B. The site in reference is > >

Re: [PHP] Closing Session

2011-03-31 Thread Ashley Sheridan
On Thu, 2011-03-31 at 16:40 -0400, Ethan Rosenberg wrote: > At 02:12 PM 3/31/2011, Ashley Sheridan wrote: > >On Thu, 2011-03-31 at 13:54 -0400, Ethan Rosenberg wrote: > > > > > At 01:30 PM 3/31/2011, Daniel Brown wrote: > > > >On Thu, Mar 31, 2011 at 13:09, Ethan Rosenberg > > wrote: > > > > > D

Re: [PHP] Closing Session

2011-03-31 Thread Daniel Brown
On Thu, Mar 31, 2011 at 16:40, Ethan Rosenberg wrote: > > > Ash - > > I can be working on more than one program simultaneously and have one tab > open w/ program A and another w/ program B.  The site in reference is > "http://localhost"; > > I hope this helps. Ah, but running on

Re: [PHP] Closing Session

2011-03-31 Thread Ethan Rosenberg
At 02:12 PM 3/31/2011, Ashley Sheridan wrote: On Thu, 2011-03-31 at 13:54 -0400, Ethan Rosenberg wrote: > At 01:30 PM 3/31/2011, Daniel Brown wrote: > >On Thu, Mar 31, 2011 at 13:09, Ethan Rosenberg wrote: > > > Dear List - > > > > > > Thanks for your help. > > > > > > How do I close a sessio

[PHP] Re: session variable problem

2011-03-31 Thread markb
On 3/25/2011 12:09 PM, markb wrote: Very rusty with PHP. We moved our web site to a new hosting service (godaddy). PHP changed from 4x to 5.2.17. I can no longer change $_SESSION variables after the first use. First call to form - start session create variables Second call - can read variables, c

Re: [PHP] Closing Session

2011-03-31 Thread Daniel Brown
On Thu, Mar 31, 2011 at 13:54, Ethan Rosenberg wrote: > > That is what I have. So now the guessing game begins, I suppose, right? What happened to rephrasing the original question, Ethan? ;-P (And why did you send me a link to your copy of WinZip?) -- Network Infrastructure Mana

Re: [PHP] is there a static constructor?

2011-03-31 Thread Admin
Why not just create a no named function in the top of the class. This this way it loads on include. Richard Buskirk Sent from my iPhone On Mar 31, 2011, at 12:56 AM, "D. Dante Lorenso" wrote: > All, > > I want to build a config file class that gets called statically. Is there > such a thing

Re: [PHP] Closing Session

2011-03-31 Thread Ashley Sheridan
On Thu, 2011-03-31 at 13:54 -0400, Ethan Rosenberg wrote: > At 01:30 PM 3/31/2011, Daniel Brown wrote: > >On Thu, Mar 31, 2011 at 13:09, Ethan Rosenberg wrote: > > > Dear List - > > > > > > Thanks for your help. > > > > > > How do I close a session form the terminal? I need the ability to do thi

Re: [PHP] Closing Session

2011-03-31 Thread Ethan Rosenberg
At 01:30 PM 3/31/2011, Daniel Brown wrote: On Thu, Mar 31, 2011 at 13:09, Ethan Rosenberg wrote: > Dear List - > > Thanks for your help. > > How do I close a session form the terminal? I need the ability to do this > for debugging. I often have more than one session open at the same time, so

Re: [PHP] Closing Session

2011-03-31 Thread Daniel Brown
On Thu, Mar 31, 2011 at 13:09, Ethan Rosenberg wrote: > Dear List - > > Thanks for your help. > > How do I close a session form the terminal?  I need the ability to do this > for debugging.  I often have more than one session open at the same time, so > creating a program with session_start() and

RE: [PHP] Closing Session

2011-03-31 Thread Jay Blanchard
[snip]How do I close a session form the terminal?[/snip] http://php.net/manual/en/function.session-destroy.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Closing Session

2011-03-31 Thread Ethan Rosenberg
Dear List - Thanks for your help. How do I close a session form the terminal? I need the ability to do this for debugging. I often have more than one session open at the same time, so creating a program with session_start() and session_unset() or session_destoy() would probably not work.

Re: [PHP] neubie seeking answers

2011-03-31 Thread Steve Staples
On Thu, 2011-03-31 at 17:34 +0100, Stuart Dallas wrote: > On Thursday, 31 March 2011 at 17:24, Kirk Bailey wrote: > I need to extract the name of the subdirectory a page lives in to > > use in the title for that page. This will be returned as a string to > > echo to the output stream. Now how the

Re: [PHP] neubie seeking answers

2011-03-31 Thread Steve Staples
On Thu, 2011-03-31 at 12:24 -0400, Kirk Bailey wrote: > I need to extract the name of the subdirectory a page lives in to > use in the title for that page. This will be returned as a string to > echo to the output stream. Now how the heck do I do that?!? > > -- > end > > Very Truly yours, >

Re: [PHP] neubie seeking answers

2011-03-31 Thread Stuart Dallas
On Thursday, 31 March 2011 at 17:24, Kirk Bailey wrote: I need to extract the name of the subdirectory a page lives in to > use in the title for that page. This will be returned as a string to > echo to the output stream. Now how the heck do I do that?!? $dir = basename(dirname(__FILE__)); -Stu

Re: [PHP] neubie seeking answers

2011-03-31 Thread Richard Quadling
On 31 March 2011 17:24, Kirk Bailey wrote: > I need to extract the name of the subdirectory a page lives in to use in the > title for that page. This will be returned as a string to echo to the output > stream. Now how the heck do I do that?!? __DIR__ is the name of the directory that the __FILE_

[PHP] neubie seeking answers

2011-03-31 Thread Kirk Bailey
I need to extract the name of the subdirectory a page lives in to use in the title for that page. This will be returned as a string to echo to the output stream. Now how the heck do I do that?!? -- end Very Truly yours, - Kirk Bailey, Largo Florida

Re: [PHP] If Statements Array and Notice Undefined Index

2011-03-31 Thread Nicholas Cooper
On 31 March 2011 15:53, Stuart Dallas wrote: > On Thursday, 31 March 2011 at 15:45, Nicholas Cooper wrote: > Good day, > > > > I have three arrays A, B and C. Anyone of them might not have the 'id' > key > > set which will give the Notice "Undefined index: id". > > > > I just wanted to know what

[PHP] Re: session_start() may take 5 seconds :(

2011-03-31 Thread Tolas Anon
On Thu, Mar 31, 2011 at 4:53 PM, Tolas Anon wrote: > On Thu, Mar 31, 2011 at 7:58 AM, Tolas Anon wrote: >> My web-app sometimes takes just over 5 seconds to execute a single >> start_session() statement. >> No other connections are open to the site when i hit the button that >> makes this happen,

[PHP] Re: session_start() may take 5 seconds :(

2011-03-31 Thread Tolas Anon
On Thu, Mar 31, 2011 at 7:58 AM, Tolas Anon wrote: > My web-app sometimes takes just over 5 seconds to execute a single > start_session() statement. > No other connections are open to the site when i hit the button that > makes this happen, the session is just 78kb on a local disk, and it's > cons

Re: [PHP] If Statements Array and Notice Undefined Index

2011-03-31 Thread Stuart Dallas
On Thursday, 31 March 2011 at 15:45, Nicholas Cooper wrote: Good day, > > I have three arrays A, B and C. Anyone of them might not have the 'id' key > set which will give the Notice "Undefined index: id". > > I just wanted to know what the correct approach to this problem would be; > without maki

[PHP] If Statements Array and Notice Undefined Index

2011-03-31 Thread Nicholas Cooper
Good day, I have three arrays A, B and C. Anyone of them might not have the 'id' key set which will give the Notice "Undefined index: id". I just wanted to know what the correct approach to this problem would be; without making the code overly complicated to read by introducing a number of "if is

Re: [PHP] Path question

2011-03-31 Thread tedd
At 9:18 PM -0400 3/28/11, Jack wrote: Hello All, Is there a smarter way to do includes by setting up a path or something where I don't have to include /home/domain.com/includes/include_file.php Apparently my path is as shown above, but I would prefer to just put in /includes/include_file.php

Re: [PHP] is there a static constructor?

2011-03-31 Thread Darren Karstens
class Daz_Config { private static $instance; private function __construct(){ $this->load(); } private function load() { ... } public function get($key) { ... } public static getInstance(){ if (!self::$instance) self::$instance = new Daz_Config();