Re: [PHP] Arrays

2013-02-26 Thread Karl DeSaulniers
On Feb 26, 2013, at 10:35 PM, tamouse mailing lists wrote: On Mon, Feb 25, 2013 at 9:51 PM, Karl DeSaulniers > wrote: Never mind. I found a different function that reads out the children as well into the array. function xml_parse_into_assoc($data) { $

Re: [PHP] Arrays

2013-02-26 Thread tamouse mailing lists
On Mon, Feb 25, 2013 at 9:51 PM, Karl DeSaulniers wrote: > Never mind. I found a different function that reads out the children as well > into the array. > > > function xml_parse_into_assoc($data) { > $p = xml_parser_create(); > >

Re: [PHP] Stupid question

2013-02-26 Thread tamouse mailing lists
On Tue, Feb 26, 2013 at 4:41 PM, Jim Lucas wrote: > On 02/26/2013 01:27 PM, Curtis Maurand wrote: >> >> I have the following: >> >> $dsn = "mysqli://$username:$password@$hostname2/$database"; >> $options = array( >> 'debug' => 3, >> 'result_buffering' => false, >> ); >> $dbh =& MDB2::factory($dsn,

Re: [PHP] Cold Intermediate Programmer trying to modularize website...

2013-02-26 Thread tamouse mailing lists
Have you considered setting this up in wordpress? On Tue, Feb 26, 2013 at 5:14 PM, Barry Smith wrote: > Yes, Jim, and "tamouse", > > Apologies for the length of this response. > > I am asking for help organizing the rewrite of the site, from a LOT of > HTMLs that have 90% in common, containing a

Re: [PHP] Lifetime

2013-02-26 Thread shiplu
Constants are available as long as the PHP process is executing. Destructors are called before a class instance is being wiped out from memory. But it does not remove a class or undefine a class. It works with instance. So a class constant never gets undefined. It stays with class definition.

[PHP] Lifetime

2013-02-26 Thread Brian Smither
I'm curious to know what the lifetime of a constant is. I know that sounds like a stupid question, but the context is this: I have a file I am writing to up to the very last possible micro-second. As such, I know that as PHP is destroying itself after having executed the last statement in the p

Re: [PHP] Cold Intermediate Programmer trying to modularize website...

2013-02-26 Thread Barry Smith
Yes, Jim, and "tamouse", Apologies for the length of this response. I am asking for help organizing the rewrite of the site, from a LOT of HTMLs that have 90% in common, containing a couple of php links to do a php mail form and command, and an article... to a "template-article-footer" format. I

Re: [PHP] Stupid question

2013-02-26 Thread Jim Lucas
On 02/26/2013 01:27 PM, Curtis Maurand wrote: I have the following: $dsn = "mysqli://$username:$password@$hostname2/$database"; $options = array( 'debug' => 3, 'result_buffering' => false, ); $dbh =& MDB2::factory($dsn, $options); if (PEAR::isError($mdb2)) { die($mdb2->getMessage()); } funct

Re: [PHP] Stupid question

2013-02-26 Thread Serge Fonville
Hi, I'm getting: Call to undefined method MDB2_Error::fetchrow() Have your checked if $dbh->query() throws an error? It seems $result is a different type than expected. HTH Kind regards/met vriendelijke groet, Serge Fonville http://www.sergefonville.nl Convince Microsoft! They need to add T

Re: [PHP] Stupid question

2013-02-26 Thread Curtis Maurand
On 2/26/2013 4:33 PM, Daniel Brown wrote: On Tue, Feb 26, 2013 at 4:27 PM, Curtis Maurand wrote: I have the following: $dsn = "mysqli://$username:$password@$hostname2/$database"; $options = array( 'debug' => 3, 'result_buffering' => false, ); $dbh =& MDB2::factory($dsn, $option

Re: [PHP] Stupid question

2013-02-26 Thread Ashley Sheridan
Daniel Brown wrote: >On Tue, Feb 26, 2013 at 4:27 PM, Curtis Maurand >wrote: >> I have the following: >> >> $dsn = "mysqli://$username:$password@$hostname2/$database"; >> $options = array( >> 'debug' => 3, >> 'result_buffering' => false, >> ); >> $dbh =& MDB2::factory($dsn, $option

Re: [PHP] Stupid question

2013-02-26 Thread Daniel Brown
On Tue, Feb 26, 2013 at 4:27 PM, Curtis Maurand wrote: > I have the following: > > $dsn = "mysqli://$username:$password@$hostname2/$database"; > $options = array( > 'debug' => 3, > 'result_buffering' => false, > ); > $dbh =& MDB2::factory($dsn, $options); > if (PEAR::isError($m

[PHP] Stupid question

2013-02-26 Thread Curtis Maurand
I have the following: $dsn = "mysqli://$username:$password@$hostname2/$database"; $options = array( 'debug' => 3, 'result_buffering' => false, ); $dbh =& MDB2::factory($dsn, $options); if (PEAR::isError($mdb2)) { die($mdb2->getMessage()); }