23481 Posts in 18965 Topics by 2878 members
|Go to End|
26 January 2010 at 3:40am
I have been working on a project that I commit to SVN and just checked that project out to the server. It has been working on the dev server for quite some time until the latest update to the code which had nothing to do with the file being referred to. I can't seem to understand this error as it seems to be coming from outside of SilverStripe:
Fatal error: Call to undefined method stdClass::write() in /......../code/WebPageRequestMultiForm.php on line 38
The line of code being referred to (and preceding lines):
$webReq = new WebPageRequest();
//now save the resources and their web request (the one we just saved)
$records = array();
foreach ($ResID as $ID)
$record = DataObject::get_one('ProjectResource', "`ProjectResource`.`ID`='$ID'");
$record->WebPageRequestID = $webReq->ID;
This is a very simple write statement on an object of type DataObject.
And yes, all the directories are owned (therefore r/w) by apache so permissions don't appear to be a problem, as per some other posts.
Any direction with regards to this?
3 February 2010 at 2:48am
Any ideas at all would be very helpful. This is an urgent matter. Even just ideas will help.
3 February 2010 at 4:12am
Did you check that every get_one in fact returns a valid DataObject?
3 February 2010 at 5:39am
Thanks so much for helping! You're right, I didn't do the basic checking. I really appreciate your help!
|Go to Top|