Re: Best practice

From: Date: Fri, 29 Apr 2005 16:43:16 +0000
Subject: Re: Best practice
References: 1 2  Groups: php.gtk.general 
Request: Send a blank email to php-gtk-general+get-5797@lists.php.net to get a copy of this message
Forgot to mention, I'm running a php 5.1 snapshot in combination with php-gtk2. Sander Op vrijdag 29 april 2005 17:30, schreef u: > Hello Sander, > > > This is the line I'm having trouble with: > > $this->vbox1->pack_start ($button); > > The problem is PHP4 which isn't capable doing this. > > > What's best practice to solve this? Should I do something like this: > > $vbox1 = &$this->vbox1; > > Yes, that's a good one. But IMO you don't need the "&". > > PHP5 and PHP-Gtk2 allow the first statement, so the following is possible: > $this->button->get_label()->set_text("hello"); > > > Regards/MfG, > Christian Weiske

« previous php.gtk.general (#5797) next »