Re: [PHP] Re: PHP5 OOP: Abstract classes, multiple inheritance and constructors

2013-06-21 Thread Micky Hulse
Thanks for tips David! I'll play with your suggestion. I've never used abstract methods, but if I'm understanding the code you posted, they look pretty useful. I may be back with questions. Appreciate the help. :) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://

Re: [PHP] Re: PHP5 OOP: Abstract classes, multiple inheritance and constructors

2013-06-21 Thread David Harkness
There's no way to bypass an overridden method using "parent", but you could add an abstract method that Child would implement. class Parent function __construct() { $this->foo = $this->getFoo(); } abstract function getFoo(); } David

[PHP] Re: PHP5 OOP: Abstract classes, multiple inheritance and constructors

2013-06-21 Thread Micky Hulse
On Fri, Jun 21, 2013 at 12:54 PM, Micky Hulse wrote: > 2. Is there a way for me to pass $foo to the parent class, from the > child, without having to ferry that variable through the abstract > class? I should mention, I'm working on some code where I don't have the ability to modify the "parent"

Re: [PHP] Re: php5 - website development - what next

2010-10-08 Thread Laruence
Hi: good idea. I need assistance. lol, http://code.google.com/p/yafphp/ On 10/09/2010 09:22, Sharl.Jimh.Tsin wrote: how about woking on open source projects? Best regards, Sharl.Jimh.Tsin (From China) 2010/10/8 Nathan Rixham: Rakesh Mishra wrote: Hi All, I am PHP 4& PHP 5 dev

Re: [PHP] Re: php5 - website development - what next

2010-10-08 Thread Sharl.Jimh.Tsin
how about woking on open source projects? Best regards, Sharl.Jimh.Tsin (From China) 2010/10/8 Nathan Rixham : > Rakesh Mishra wrote: >> >> Hi All, >> >> I  am PHP 4 & PHP 5 developer for last 6 yrs. Last year  also got Zend >> certification. >> Since now I have work on different CMS, Social Ne

[PHP] Re: php5 - website development - what next

2010-10-08 Thread Nathan Rixham
Rakesh Mishra wrote: Hi All, I am PHP 4 & PHP 5 developer for last 6 yrs. Last year also got Zend certification. Since now I have work on different CMS, Social Networking, telecome , horse racing domains. But now I am little bored with developing website. What other things I can do with PHP ?

[PHP] Re: PHP5+APACHE 2.2 + Windows 2003 production server

2009-08-26 Thread Shawn McKenzie
Andrioli Darvin wrote: > Hi all > > PHP manual state "We do not recommend using a threaded MPM in production > with Apache 2. Use the prefork MPM instead, or use Apache 1. For information > on why, read the related FAQ entry on using Apache2 with a threaded MPM" ( > http://www.php.net/manual/en/in

[PHP] Re: PHP5 based Web-Chat?

2009-05-21 Thread Nathan Rixham
Michelle Konzack wrote: Hello Nathan, Am 2009-05-21 13:44:38, schrieb Nathan Rixham: Nothing :D - anything php based would involve polling which will kill any server when trying to create a realtime chat environment (1 request per second per chatter + 1 for each message send + normal hi

[PHP] Re: PHP5 based Web-Chat?

2009-05-21 Thread Michelle Konzack
Hello Nathan, Am 2009-05-21 13:44:38, schrieb Nathan Rixham: > Nothing :D > - anything php based would involve polling which will kill > any server when trying to create a realtime chat environment > (1 request per second per chatter + 1 for each message send + normal > hits) - so say 30 ch

[PHP] Re: PHP5 based Web-Chat?

2009-05-21 Thread Nathan Rixham
Michelle Konzack wrote: Hello, I like to install a forum for my customers and additional a PHP5 based Web-Chat system with publich and private chatrooms. What can you recommend? Nothing :D - anything php based would involve polling which will kill any server when trying to create a realti

Re: [PHP] Re: php5 with apache 1.x -> white page

2009-01-17 Thread Merlin Morgenstern
Ashley Sheridan schrieb: On Sat, 2009-01-17 at 15:31 +, Nathan Rixham wrote: Merlin Morgenstern wrote: got it :-) Both are needed! --with-mysql=/usr/local/mysql' '--with-pdo-mysql=/usr/local/mysql/' Merlin Morgenstern schrieb: Hi there, after strugling a while with the installation of

Re: [PHP] Re: php5 with apache 1.x -> white page

2009-01-17 Thread Ashley Sheridan
On Sat, 2009-01-17 at 15:31 +, Nathan Rixham wrote: > Merlin Morgenstern wrote: > > > > > > got it :-) Both are needed! > > --with-mysql=/usr/local/mysql' '--with-pdo-mysql=/usr/local/mysql/' > > > > Merlin Morgenstern schrieb: > >> Hi there, > >> > >> after strugling a while with the instal

[PHP] Re: php5 with apache 1.x -> white page

2009-01-17 Thread Nathan Rixham
Merlin Morgenstern wrote: got it :-) Both are needed! --with-mysql=/usr/local/mysql' '--with-pdo-mysql=/usr/local/mysql/' Merlin Morgenstern schrieb: Hi there, after strugling a while with the installation of php5 on an older suse system with mysql 3.x and apache 1.x I got it compiled and i

[PHP] Re: php5 with apache 1.x -> white page

2009-01-17 Thread Merlin Morgenstern
got it :-) Both are needed! --with-mysql=/usr/local/mysql' '--with-pdo-mysql=/usr/local/mysql/' Merlin Morgenstern schrieb: Hi there, after strugling a while with the installation of php5 on an older suse system with mysql 3.x and apache 1.x I got it compiled and installed. Apache starts a

[PHP] Re: PHP5 oop question...

2007-05-28 Thread Jared Farrish
When in-scope and using static functions, use self: class Static_Ex { private static $variable = 'This is a static variable'; public static function tryStatic() { return self::$variable; } } echo Static_Ex::tryStatic(); If you think about it, there is no $this in a static fun

[PHP] Re: PHP5 Static functions called through __call() that don't exist... yet

2007-05-19 Thread Greg Beaver
Jared Farrish wrote: > Hi all, > > I am building an assertType object using static functions. What I want to > keep away from is the following: > > > public static function assertString($para){ >return $answer; > }; > public static function assertBool($para){ >return $answer; > }; > ...

[PHP] Re: PHP5 Static functions called through __call() that don't exist... yet

2007-05-19 Thread Emil Ivanov
Hi, I also think this a good proposal, but you might consider writing to the internals group, as this group is only for discussions and most of the people that read it are PHP users and have no idea how the language is made (including me). Regards, Emil Ivanov ""Jared Farrish"" <[EMAIL PROTECT

[PHP] Re: PHP5 Static functions called through __call() that don't exist... yet

2007-05-18 Thread Jared Farrish
Hi all, Here is more code, with a test case included. What I would prefer to do is call TypeAssist::$string(), instead of TypeAssist::$a->string(). Or at least __construct() the $a object. $method; } public static function assertStandardTypes($para) { $r = TypeAssert::g

[PHP] Re: php5 cert

2007-05-18 Thread itoctopus
I know someone who easily passed PHP4, but never made it on PHP5, so don't expect the same level of questions. -- itoctopus - http://www.itoctopus.com ""Greg Donald"" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Anyone wanna share their insights into the php5 cert test? The ph

Re: [PHP] Re: PHP5 Cross Compilation

2007-01-19 Thread Jochem Maas
Kiran Malla wrote: > Hello, > > What are all the flags and variables to set to cross compile PHP for arm? I > didn't get any info on the query I posted earlier. If anyone has tried php > on arm linux, please let me know the steps. if google didn't give any answers then I might suggest the php int

[PHP] Re: PHP5 Cross Compilation

2007-01-19 Thread Kiran Malla
Hello, What are all the flags and variables to set to cross compile PHP for arm? I didn't get any info on the query I posted earlier. If anyone has tried php on arm linux, please let me know the steps. Thanks so much, Regards, Kiran On 1/18/07, Kiran Malla <[EMAIL PROTECTED]> wrote: Hello,

[PHP] Re: PHP5 Inheritance/method override problem

2006-12-06 Thread Richard Morris
Edward Kay wrote: Hi Richard, This is very strange. I can certainly reproduce the problem. Putting a var_dump($this) in ClassA's save method shows that PHP sees $this as an instance of ClassB - when it should be of ClassA. what *you* think it should be and what php's developers decided it shoul

Re: [PHP] Re: PHP5 || Catch Error & Send POST Vars...

2006-10-06 Thread Richard Lynch
On Thu, October 5, 2006 4:43 pm, sit1way wrote: > I'd like to catch errors and send POST vars to my error display page. > > So: > > try { > $r = new query($sql); > > if(!$r) { > throw new Exception($err); > } > } > catch (Exception $e) { > $this->err_msg = $e->getMessage();

[PHP] Re: PHP5 || Catch Error & Send POST Vars...

2006-10-05 Thread sit1way
Hey all. Loving Try Catch error handling in PHP5! Got a problem though: I'd like to catch errors and send POST vars to my error display page. So: try { $r = new query($sql); if(!$r) { throw new Exception($err); } } catch (Exception $e) { $this->err_msg = $e->getMessag

[PHP] Re: PHP5 + Mysql5 + Apache 2.0.55

2006-01-14 Thread Libit
Erik Gyepes wrote: Hi all. I'm trying to set up mysql 5 with php 5 on my windows machine, but I can't get work it. Also I can't see any loaded extensions with phpinfo(). I have set extensions directory in php.ini, PATH dir in windows, what else I may to do? I used linux a lot of time and now

[PHP] Re: PHP5, Soap, WSDL, and unbounded xsd:choice types.

2006-01-10 Thread Rob
Simon Detheridge wrote: What I want PHP to do, is enable me to access my 'bar' and 'baz' elements in the order in which they appear in the document, instead of having it glob them together for each type. However, I am unable to modify the output of the webservice itself as it interoperates

[PHP] Re: Php5 SOAP WSDL parsing

2006-01-09 Thread Simon Detheridge
Quoting David Grant <[EMAIL PROTECTED]>: It would appear you've not included the full message. Please look at the source of the message in your web browser. The space between unexpected and "in complexType" probably contains an XML tag. Uh, indeed I was. It was an unexpected that was causi

[PHP] Re: Php5 SOAP WSDL parsing

2006-01-09 Thread Rob
Simon Detheridge wrote: The output says: SoapFault exception: [WSDL] SOAP-ERROR: Parsing Schema: unexpected in complexType in /var/www/localhost/htdocs/soap1.php:5 Stack trace: #0 /var/www/localhost/htdocs/soap1.php(5): SoapClient->__construct('http://www.symg...') #1 {main} attribute defi

Re: [PHP] Re: php5 call by refference

2005-11-21 Thread Georgi Ivanov
Thanks ! It's all clear now . :) On Monday 21 November 2005 14:45, Oliver Grätz wrote: > Georgi Ivanov schrieb: > > Hi, > > AFAIK, in PHP5 one can't call function with function parameters . > > The error is that you only can pass variables by reference. > > foo(strlen('aaa'),strlen('')); > >

[PHP] Re: php5 call by refference

2005-11-21 Thread Oliver Grätz
Georgi Ivanov schrieb: > Hi, > AFAIK, in PHP5 one can't call function with function parameters . > The error is that you only can pass variables by reference. > foo(strlen('aaa'),strlen('')); > > Is there some sort of workaround ? First of all, the problem with this arises if your function fo

[PHP] Re: php5 / php4 - MySQL/SQLite

2005-11-09 Thread Oliver Grätz
Danny schrieb: > Let me open a discussion about php5 / php4 Fine. Let's keep it short ;-) > Why upgrade? Because you want support for proper OOP. Most of the other changes can be like SQLite can also be used with PHP4. > It worth? If you see the benefits of interfaces, object overloading, auto

[PHP] Re: php5 / php4 - MySQL/SQLite

2005-11-08 Thread Petr Smith
Danny wrote: Hi, Let me open a discussion about php5 / php4 Why upgrade? It worth? Benefits? Code programming changes? Is there and end-of-life for php4, in the near/medium future? What about MySQL and SQLite. What is the future of both? I would like to open a discussion about the future of b

[PHP] Re: PHP5 OOP how do I get the list of all classes dynamically?

2005-10-05 Thread Oliver Grätz
You can get an array of all declared classes with http://de.php.net/manual/en/function.get-declared-classes.php If you need more context (e.g. only subclasses of X) you should definitely have a close look at the reflection api. AllOLLi "Being lectured by the President on fiscal res

[PHP] Re: php5<-->com terribly wrong ?

2005-10-02 Thread Sonia
If you need this functionality then you should go back to PHP 4 the version that worked for you. I also have problems with this and winmgmts object. some classes work others don't, most times it's a VARIANT type problems. I know Wez is really busy but if you keep checking the snap shots you will se

[PHP] Re: PHP5, Tidy: node and parent node

2005-07-15 Thread Markus Fischer
Markus Fischer wrote: I'm trying to figure out the parent of a node in tidy. As it seems to me there's no property/method available for this. I really want to avoid traversing the whole document and build the relation myself; this is getting pretty slow. PHP5 currently doesn't feature this m

[PHP] Re: php5-mysqli

2005-05-05 Thread Ryan Faricy
"Nsk" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > which config files are responsible for loading mysqli in apache/php5 ? php.ini ;; Old MySQL support extension=mysql.so ;; New MySQL support. extension=mysqli.so -- PHP General Mailing List (http://www.php.net/) To unsubscribe

[PHP] Re: PHP5 & JBOSS

2005-03-14 Thread Jason Barnett
David Joffrin wrote: > Hi, > > I searched on the net, found a lot of articles about it... followed all > the various one by one, tried a lot, but I am getting the famous error: > java.lang.UnsatisfiedLinkError: no php5servlet.dll in java.library.path. > ... > > I modified my application to display

[PHP] Re: PHP5 DOM - DomDocumentFragments empty

2005-03-02 Thread Jason Barnett
Here is a modified version of the code that you posted that should explain it. content XMLDATA; $dom = new DomDocument; $dom->loadXML( $xmlData ); $dom2 = new DomDocument; $fragment = $dom2->createDocumentFragment(); foreach( $dom->childNodes AS $node ) { $newNode = $dom2->imp

Re: [PHP] Re: PHP5 Static Object Function Issue

2005-03-01 Thread Gavin Roy
Well yes and no, conceivably, the system has no idea what singletons are out there other than what is specified in a configuration file. You are in essence hard coding the class name in the switch. Gavin On Tue, 01 Mar 2005 17:47:24 -0500, Jason Barnett <[EMAIL PROTECTED]> wrote: > A switch sta

[PHP] Re: PHP5 Static Object Function Issue

2005-03-01 Thread Jason Barnett
A switch statement can accomplish what you seek. $i) ? 'MyClass' : null); $singleton[] = getSingleton($class); } var_dump($singleton); ?> -- Teach a man to fish... NEW? | http://www.catb.org/~esr/faqs/smart-questions.html STFA | http://marc.theaimsgroup.com/?l=php-general&w=2 STFM | http:/

Re: [PHP] Re: php5 and globals?

2005-02-20 Thread Guillermo Nouche
On Sun, 20 Feb 2005 15:14:27 +0100, M. Sokolewicz <[EMAIL PROTECTED]> wrote: > Mike wrote: > > > > > I have read that php5 does something different with global_vars. I know that > > many of my clients rely on them working. Will thinks start breaking after I > > upgrade from 4.3.10 to 5.3? > > > >

[PHP] Re: php5 and globals?

2005-02-20 Thread M. Sokolewicz
Mike wrote: I have read that php5 does something different with global_vars. I know that many of my clients rely on them working. Will thinks start breaking after I upgrade from 4.3.10 to 5.3? TIA "something different" being...? maybe you mean register_globals? that change goes back to php 4.2.0,

[PHP] Re: PHP5 + SPL - Creating an object as an array.

2005-02-03 Thread Yotam Ofek
Jason Barnett wrote: Yotam Ofek wrote: I would like to create an object like this: class TestClass { private $some_array; public $just; public $some; public $public; public $vars; } ?> Is it possible, through SPL, to make the class accessible as "$testclass['array_key']", whic

[PHP] Re: PHP5 + SPL - Creating an object as an array.

2005-01-31 Thread Jason Barnett
Yotam Ofek wrote: I would like to create an object like this: class TestClass { private $some_array; public $just; public $some; public $public; public $vars; } ?> Is it possible, through SPL, to make the class accessible as "$testclass['array_key']", which will return the val

[PHP] Re: PHP5 stable enough for webapps ?

2005-01-28 Thread Matthew Weier O'Phinney
* [EMAIL PROTECTED] <[EMAIL PROTECTED]>: > I am in the midst of getting work to implement PHP5 onto a new server for a > web based app I am doing using PEAR's DB_DataObject plus some other fancy > OO. To give them the piece of mind I would like to know if its stable enough > to run for an intranet

Re: [PHP] Re: PHP5 silently throwing exceptions???

2005-01-17 Thread Gerard Samuel
Jochem Maas wrote: Jason Barnett wrote: Gerard Samuel wrote: ... I haven't checked the source on this one so I can't guarantee that what I've said above is true, but I believe it to be true. Someone correct me if I'm wrong (wouldn't be the first time ;) seems to me like you 'on the money'. I ju

Re: [PHP] Re: PHP5 silently throwing exceptions???

2005-01-17 Thread Jochem Maas
Jason Barnett wrote: Gerard Samuel wrote: ... I haven't checked the source on this one so I can't guarantee that what I've said above is true, but I believe it to be true. Someone correct me if I'm wrong (wouldn't be the first time ;) seems to me like you 'on the money'. I just wanted to add tha

Re: [PHP] Re: PHP5 silently throwing exceptions???

2005-01-17 Thread Jason Barnett
Jochem Maas wrote: Jason Barnett wrote: Gerard Samuel wrote: I haven't checked the source on this one so I can't guarantee that what I've said above is true, but I believe it to be true. Someone correct me if I'm wrong (wouldn't be the first time ;) seems to me like you 'on the money'. I j

Re: [PHP] Re: PHP5 silently throwing exceptions???

2005-01-17 Thread Gerard Samuel
Jason Barnett wrote: Gerard Samuel wrote: Jason Barnett wrote: Gerard Samuel wrote: I've debugged it down to this -> //try //{ $db->connect(); //} //catch(databaseException $e) //{ //throw $e; //} The ::connect() method is supposed to throw a databaseException if a connection cannot be made

Re: [PHP] Re: PHP5 silently throwing exceptions???

2005-01-17 Thread Jason Barnett
Gerard Samuel wrote: Jason Barnett wrote: Gerard Samuel wrote: I've debugged it down to this -> //try //{ $db->connect(); //} //catch(databaseException $e) //{ //throw $e; //} The ::connect() method is supposed to throw a databaseException if a connection cannot be made. In my tests, connec

Re: [PHP] Re: PHP5 silently throwing exceptions???

2005-01-17 Thread Gerard Samuel
Jason Barnett wrote: Gerard Samuel wrote: Im currently using php 5.0.3 on a dev box, trying to figure out how to correctly use exceptions in my code. Exceptions can be "A Good Thing". Per chance, I was monitoring the __autoload() function, and Im noticing that calls are being made to exception cla

[PHP] Re: PHP5 silently throwing exceptions???

2005-01-17 Thread Jason Barnett
Gerard Samuel wrote: Im currently using php 5.0.3 on a dev box, trying to figure out how to correctly use exceptions in my code. Exceptions can be "A Good Thing". Per chance, I was monitoring the __autoload() function, and Im noticing that calls are being made to exception classes that I've setup.

[PHP] Re: PHP5 Namespace ?

2005-01-04 Thread Greg Beaver
Matthew Weier O'Phinney wrote: * Alawi Albaity <[EMAIL PROTECTED]>: is really that the support for namespace in php5 is removed ? or there are replacment for it ? It's been removed as it's not currently working: http://php.net/ChangeLog-5.php My understanding is that it will be at least 5.1 be

[PHP] Re: PHP5 Namespace ?

2005-01-04 Thread Matthew Weier O'Phinney
* Alawi Albaity <[EMAIL PROTECTED]>: > is really that the support for namespace in php5 is removed ? or there > are replacment for it ? It's been removed as it's not currently working: http://php.net/ChangeLog-5.php My understanding is that it will be at least 5.1 before namespaces are added

[PHP] Re: php5 webhosting

2005-01-03 Thread Greg Beaver
Greg Donald wrote: Anyone found any good deals with webhosts supporting PHP5 yet? it's not exactly for newbies, but bluga.net has been doing a fine job for me. Greg P.S. "ZCE" doesn't exactly imply newbie :) this is for others on the list -- PHP General Mailing List (http://www.php.net/) To unsub

[PHP] Re: PHP5 CLI Custom Error Reporting Doesn't Work as Expected

2004-10-24 Thread Daniel Schierbeck
Daniel Talsky wrote: Included is my reproduce code. I'm trying to write a custom error logger for my PHP CLI script. The main problem is that when I try something like a failed require() statement, my custom error reporting function tells me it got an E_WARNING, but it stops program execution, whic

Re: [PHP] Re: PHP5 and Multi Inheritance?

2004-10-17 Thread Rory Browne
I'm not sure, but I think the only way you are going to get MI in PHP, is if you implement if yourself. By this I mean, implementing the correct __get(), __set(), and __call() functions. On Sun, 17 Oct 2004 18:32:34 +0400, M Saleh EG <[EMAIL PROTECTED]> wrote: > Thanx Mathew > I guess I found it

Re: [PHP] Re: PHP5 and Multi Inheritance?

2004-10-17 Thread M Saleh EG
Thanx Mathew I guess I found it, it's disapointing though. Here was the answer: http://www.zend.com/php5/andi-book-excerpt.php#Heading3 4. Interfaces Gives the ability for a class to fulfill more than one is-a relationships. A class can inherit from one class only but may implement as many inter

[PHP] Re: PHP5 and Multi Inheritance?

2004-10-17 Thread Matthew Weier O'Phinney
* M Saleh Eg <[EMAIL PROTECTED]>: > Is direct multi inhertance supported in PHP5? I believe so -- this was one of the new features of the object model introduced in PHP5. My understanding is that you have to create interface classes that a class can then implement. Unfortunately, interface classe

Re: [PHP] Re: [PHP5] How to knwo object class name in a function

2004-10-07 Thread M. Sokolewicz
Marek Kilimajer wrote: M. Sokolewicz wrote: Frédéric hardy wrote: Hello - I have this code : abstract class foo { private __construct() {} public static getInstance() { static $instance = null; if (is_null($instance) == false) return $instance; else {

Re: [PHP] Re: [PHP5] How to knwo object class name in a function called statically

2004-10-07 Thread Marek Kilimajer
M. Sokolewicz wrote: Frédéric hardy wrote: Hello - I have this code : abstract class foo { private __construct() {} public static getInstance() { static $instance = null; if (is_null($instance) == false) return $instance; else { $class = __CLASS__;

[PHP] Re: [PHP5] How to knwo object class name in a function called statically

2004-10-07 Thread M. Sokolewicz
Frédéric hardy wrote: Hello - I have this code : abstract class foo { private __construct() {} public static getInstance() { static $instance = null; if (is_null($instance) == false) return $instance; else { $class = __CLASS__; return new

Re: [PHP] Re: [PHP5] paradox ? Bug ?

2004-09-03 Thread Daniel Kullik
Well alright, then I ought to read the suggested sources. Thanks for the advice. Anyway, doesn't it cause trouble to have $array as a private member? Frédéric hardy wrote: Moreover, $foo['bar'] = 'bar' work perfectly... Fred. Frédéric Hardy wrote: WRONG ! Read the manual about __set() and __get()

Re: [PHP] Re: [PHP5] paradox ? Bug ?

2004-09-03 Thread Frédéric Hardy
Moreover, $foo['bar'] = 'bar' work perfectly... Fred. Frédéric Hardy wrote: WRONG ! Read the manual about __set() and __get(). And read http://www.php.net/~helly/php/ext/spl/index.html about arrayAccess. Php 5 allow you to "overloading" property dynamicaly with __set() and __get(). And you can ac

Re: [PHP] Re: [PHP5] paradox ? Bug ?

2004-09-03 Thread Frédéric Hardy
WRONG ! Read the manual about __set() and __get(). And read http://www.php.net/~helly/php/ext/spl/index.html about arrayAccess. Php 5 allow you to "overloading" property dynamicaly with __set() and __get(). And you can access an object like an array with arrayAccess interface. There is no nonsen

[PHP] Re: [PHP5] paradox ? Bug ?

2004-09-03 Thread Daniel Kullik
Hello Frédéric. This is neither a bug nor a paradox. The code you've posted just contains some nonsense. $foo['bar'] = 'bar'; cannot work since $foo is an object and not an array. And even $foo->bar = 'bar'; cannot work because there is no property $bar. Frédéric hardy wrote: Hello - I think t

Re: [PHP] Re: [PHP5]__get, __set and isset()

2004-09-01 Thread Marek Kilimajer
Catalin Trifu wrote: Hi, Is this really a bug. I think not. There is no variable $o->a or $a->b in the class OO there is only the variable $elem and $a and $b is a member of that array So ... The fact that PHP5 provides __set and __get magic functions does not mean that the

Re: [PHP] Re: [PHP5]__get, __set and isset()

2004-09-01 Thread Frédéric Hardy
I am agree with Catalin about "no property is created", that __set() and __get() create "virtual" property. But, for the programmer, property which was set whith __set() and __get() ARE REAL, and must be use as real property. Conclusion : if php provide __set() and __get() to simulate object p

Re: [PHP] Re: [PHP5]__get, __set and isset()

2004-08-31 Thread Daniel Schierbeck
Catalin Trifu wrote: Actually i think no property is created; not in the sense of real object property. The only "real" property of the object is $elem. The $o->a, and $o->b are, IMHO, not object properties; It is true that one can access $o->a and $o->b, but what is actually return

[PHP] Re: [PHP5]__get, __set and isset()

2004-08-31 Thread Greg Beaver
Frédéric hardy wrote: Is it possible to do something like this : class foo { private $array = array(); function __construct() { ... } function __get($key) { return (isset($this->array[$key]) == false ? null : $this->array[$key]); } function __set($k

Re: [PHP] Re: [PHP5]__get, __set and isset()

2004-08-31 Thread Catalin Trifu
Actually i think no property is created; not in the sense of real object property. The only "real" property of the object is $elem. The $o->a, and $o->b are, IMHO, not object properties; It is true that one can access $o->a and $o->b, but what is actually returned is a member of the

Re: [PHP] Re: [PHP5]__get, __set and isset()

2004-08-31 Thread Frédéric Hardy
But there is no property set to NULL !! Fred. M. Sokolewicz wrote: next time, please read the isset documentation carefully. I quote: [quote]isset() will return FALSE if testing a variable that has been set to NULL.[/quote] Catalin Trifu wrote: Hi, Is this really a bug. I think not.

Re: [PHP] Re: [PHP5]__get, __set and isset()

2004-08-31 Thread Frédéric Hardy
Yes but not :-). With you use these magic functions, when you write $o->a = 'foo', you create a property in the object. Not ? Even if it is stored in an array member, __set() create a property and __get() retrieve its value. Doc says : >The $name parameter used is the name of the variable th

[PHP] Re: [PHP5]__get, __set and isset()

2004-08-31 Thread Daniel Schierbeck
M. Sokolewicz wrote: next time, please read the isset documentation carefully. I quote: [quote]isset() will return FALSE if testing a variable that has been set to NULL.[/quote] Catalin Trifu wrote: Hi, Is this really a bug. I think not. There is no variable $o->a or $a->b in the

[PHP] Re: [PHP5]__get, __set and isset()

2004-08-31 Thread M. Sokolewicz
next time, please read the isset documentation carefully. I quote: [quote]isset() will return FALSE if testing a variable that has been set to NULL.[/quote] Catalin Trifu wrote: Hi, Is this really a bug. I think not. There is no variable $o->a or $a->b in the class OO there is onl

[PHP] Re: [PHP5]__get, __set and isset()

2004-08-31 Thread Catalin Trifu
Hi, Is this really a bug. I think not. There is no variable $o->a or $a->b in the class OO there is only the variable $elem and $a and $b is a member of that array So ... The fact that PHP5 provides __set and __get magic functions does not mean that the actual variables exi

Re: [PHP] Re: [PHP5]__get, __set and isset()

2004-08-31 Thread Frédéric Hardy
Bug Id is 29917. Fred. Daniel Schierbeck wrote: Frédéric hardy wrote: Is it possible to do something like this : class foo { private $array = array(); function __construct() { ... } function __get($key) { return (isset($this->array[$key]) == false ? null : $

[PHP] Re: [PHP5]__get, __set and isset()

2004-08-31 Thread Daniel Schierbeck
Frédéric hardy wrote: Is it possible to do something like this : class foo { private $array = array(); function __construct() { ... } function __get($key) { return (isset($this->array[$key]) == false ? null : $this->array[$key]); } function __set($k

[PHP] Re: PHP5 Manual in PDF and for Pocket PCs

2004-07-31 Thread Chris Martin
Jason Barnett wrote: As far as I know, no one has done that yet. Although all of the PHP manual pages are written in XML so if you were so inclined you could do it yourself. And I'm sure others would appreciate it if you shared it :) You could use HTMLDoc to convert the html pages to pdf. http:

[PHP] Re: PHP5 Manual in PDF and for Pocket PCs

2004-07-31 Thread Jason Barnett
As far as I know, no one has done that yet. Although all of the PHP manual pages are written in XML so if you were so inclined you could do it yourself. And I'm sure others would appreciate it if you shared it :) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://ww

[PHP] Re: PHP5 for Fedora Core 2

2004-07-27 Thread PHPDiscuss - PHP Newsgroups and mailing lists
C.F. Scheidecker Antunes wrote: > Hello all, > Are there any pre compiled rpm packages from Fedora Core 2 yet? > If not, I will most likely built it myself. > Thanks. Any chance you can send it to me when you finish? Thanks. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, v

[PHP] RE: PHP5 - Weird Error - "cannot find element in variable"

2004-07-21 Thread Scott Hyndman
and name switched $collection->Add(new Amenity($f['position'], $f['name'], $f['context'])); $res->MoveNext(); } Original Message Subject:RE: [PHP] Re

[PHP] Re: PHP5 - Weird Error - "cannot find element in variable"

2004-07-20 Thread Jason Barnett
{ $f = $res->fields; // Position and name switched $collection->Add(new Amenity($f['position'], $f['name'], $f['context'])); $res->MoveNext(); } ---- Original Message Subject:RE: [PHP] Re: PHP5 - Weird Error - "cannot find ele

[PHP] Re: PHP5 - Weird Error - "cannot find element in variable"

2004-07-20 Thread Jason Barnett
The Object is being created perfectly, I've checked. The collection's Add() method is something like: Since you know you're adding MyObject objects, first of all check for that: public function Add(MyObject $object) public function Add($object) { $

[PHP] Re: PHP5, XPath and count()

2004-07-20 Thread Jason Barnett
To find the number of nodes in a DomNodeList you need to access the length property... sample code to do this: $xml = << The Rolling Stones Exile On Main Street Aimee Mann I'm With Stupid Bachelor No. 2 XML; $dom = new DomDocument(); $do

[PHP] Re: php5/cli/cgi/stdin/signal bug ?

2004-07-19 Thread franck
When using /dev/fd/0 (not php://stdin) in the two fopen functions, it works "perfectly" with cli AND cgi version -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: PHP5 and pass by reference bug.

2004-07-16 Thread Curt Zirzow
* Thus wrote Daevid Vincent: > Yeah, I get what references are. The point is that when it was on the user > to decide, they could do it. Now that PHP5 makes you put the & in the > function declaration instead of the passing parameter, you don't know what > the user is going to send. Therefore it re

Re: [PHP] Re: PHP5 and pass by reference bug.

2004-07-16 Thread Justin Patrin
ince > passing add(&$x, &$y); is now invalid], it makes my function add basically > useless. > > > > > > -----Original Message- > > From: Red Wingate [mailto:[EMAIL PROTECTED] > > Sent: Friday, July 16, 2004 5:35 PM > > To: [EMAIL PROTECTED] &

RE: [PHP] Re: PHP5 and pass by reference bug.

2004-07-16 Thread Daevid Vincent
5,10); But since the function is now responsible in PHP5 to use the & [since passing add(&$x, &$y); is now invalid], it makes my function add basically useless. > -Original Message- > From: Red Wingate [mailto:[EMAIL PROTECTED] > Sent: Friday, July 16, 2004 5:35 PM &

[PHP] Re: PHP5 and pass by reference bug.

2004-07-16 Thread Red Wingate
Maybe you recheck the dokumentation on what exactly referenzes are. Do you expect the function to alter the string "something here" and every- time you later print the string within your script you get the altered one? ONLY variables can be passed by referenze ! -- red Daevid Vincent wrote: So,

[PHP] Re: PHP5 and pass by reference bug.

2004-07-16 Thread Red Wingate
Maybe you recheck the dokumentation on what exactly referenzes are. Do you expect the function to alter the string "something here" and every- time you later print the string within your script you get the altered one? ONLY variables can be passed by referenze ! -- red Daevid Vincent wrote: So,

[PHP] Re: PHP5 Install Version (Win32)

2004-07-16 Thread Lester Caine
Ron Stiemer wrote: Does anybody got some information if there will be a Win32 Install Version of PHP5 like it exists for 4.3.8 ? Personally I simply don't see the point :) Unzip the zip, tweak Apache and php.ini and I have what *I* want running in minutes. I don't want MySQL, I do use Apache2 so t

[PHP] Re: PHP5 release HTTP Authentication not working on FreeBSD.

2004-07-15 Thread Red Wingate
known problem, will be fixed soon in 5.0.1 which should be released asap William Bailey wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi Guys, I've just upgraded from 5.0 rc3 to 5.0 release on freeBSD (using the ports) and now find that HTTP Authentication dosent work. Here is the te

[PHP] Re: PHP5 Windows not built with Soap Enabled?

2004-07-14 Thread Sean Malloy
> checking the output of phpinfo() for the 5.0.0 binary from www.php.net, it > would seem there is no soap support built in at all. > > Or have I just not woken up today? I win the "You're a Dumb Ass" award for the day. "The SOAP extension isn't activated by default (PHP5 RC1). Just add "extensio

[PHP] Re: PHP5: serialize private properties

2004-06-20 Thread Christof Rath
If anyone else has the same problem, I found an entry in the bug database: http://bugs.php.net/bug.php?id=28082 c. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: [PHP5] Super constructor?

2004-06-14 Thread franciccio
ok thanks "Justin Patrin" <[EMAIL PROTECTED]> ha scritto nel messaggio news:[EMAIL PROTECTED] > Franciccio wrote: > > > If i'm not wrong php has only 1 level of depth for child class. That means > > you can only extends from 1 level up the class. > > In your example you have the class OneMore that

[PHP] Re: [PHP5] Super constructor?

2004-06-14 Thread Justin Patrin
Franciccio wrote: If i'm not wrong php has only 1 level of depth for child class. That means you can only extends from 1 level up the class. In your example you have the class OneMore that extends down from the "grandfather" Base. It is not a problem in C++ but should not work in php or either java

[PHP] Re: [PHP5] Super constructor?

2004-06-14 Thread franciccio
If i'm not wrong php has only 1 level of depth for child class. That means you can only extends from 1 level up the class. In your example you have the class OneMore that extends down from the "grandfather" Base. It is not a problem in C++ but should not work in php or either javascript. Am i wron

[PHP] Re: PHP5 RC3 Runnay Processes

2004-06-09 Thread Ben Ramsey
My advice to you is to post this to the internals@ list. They will then let you know whether you should report it at http://bugs.php.net and so forth. Michael wrote: HI, I installed PHP 5 RC3 this morning and am having some mixed results. Specifically, every so often, I will refresh a page tha

[PHP] Re: PHP5 - instanceof

2004-05-13 Thread Greg Beaver
Martin Towell wrote: I have been playing with PHP5 and am liking it more and more. But I have one question about "instanceof" If you have something like this: This would echo "BA". That's good, I understand that. Now the question: Is it possible to determine if B is an instance of A without inst

  1   2   >