Hi,
I just made first tests and got this:
Server Error
The query builder failed to execute, see the log file
for more information.
Error 500
There is nothing in midcom log.
From PHP log:
PHP Notice: Wrong type for 'midgard_topic'
constructor in
/usr/share/php/midcom/lib/midcom/baseclasses/database/topic.
php on line 28
Which means that neither string nor integer has been passed
as constructor argument for child class which extends one of
MgdSchema class ( midgard_topic in this case ).
__BUT__:
Before Midgard 1.8 beta2 is out I changed objects ( Zend and
GObject ) handlers.
There are few reasons for this change:
* Increase speed and decrease memory usage
* Keep php object as 1:1 with core's GObject
* midgard-php should be ready for features which will be
backported from 1.9
* or will be implemented in 1.9 and 1.8 branch.
* property getter and setter could be implemenetd at last
* properties like sitegroup or guid can be used as
protected ones
( even for PHP4 )
This is of course not midcom issue. I made a quick patch (
not yet commited ) so objects of child classes are now
handled correctly as long as:
* parent constructor is not overwritten.
* methods are not invoked as parent::method();
So:
class class_a extends midgard_article {
}
is absolutely enough to use such code:
$o = new class_a($id or $guid);
/* OR */
$o = new class_a();
$o->get_by_guid($guid);
I just wonder , if we should postpone midcom and midgard
release for next few days and test this issue , or should I
completely revert changes and keep Zend&GObjects
"mappings" as 1:2 ?
Piotras
-----------
This message has been sent to the Midgard Forums on http://www
.midgard-project.org/discussion/
DO NOT reply to this message by email. If you want to reply
to it, go to https://ww
w.midgard-project.org/discussion/developer-forum/reply/af253
775d2268071404c359ea284ee9e.html
Go to h
ttps://www.midgard-project.org/discussion/account/ to
update your contact details or click https://www.midgard-project.org/discussion/subscriptions/
campaign/unsubscribe/25eded291764e251a0b57d1cb42d6c4d.html
a> to unsubscribe.
|