Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Customising the CMS /

Director::test() saves results for next call?


Reply


2 Posts   1454 Views

Avatar
FlorianH

Community Member, 33 Posts

1 July 2009 at 7:51pm

Edited: 01/07/2009 7:52pm

Hello there,

I need to call the Director::test() method several times for one DataObject (with different Actions) during my own export function and it seems that Silverstripe saves a DataObject::get() result within an function in my DataObject and uses it for the next time. This only occurs when calling the Controller of the DataObject with the Director::test() method (using a rule in the cms/_config.php), if I open the page in a Browser I see that with every refresh the function works correctly without caching any results.

Any ideas?

FlorianH

Avatar
FlorianH

Community Member, 33 Posts

2 July 2009 at 12:17am

Disabling the cache Parameter in the DataObject::get_one Method did the trick.