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.

We're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

debugging why a page wont "save & publish"

Go to End

9 Posts   1759 Views


Community Member, 166 Posts

1 November 2011 at 2:54pm

I would suggest you turn on on error logging. And if that doesn't yield any interesting info, then it might be worth including debug output statements writing to the log throughout the 2 ::save(...) functions.

It's crude, but sometimes that's the only way to get to in code and see the state of properties, where stepping through code isn't possible (as when you need to replicate it on production server). (It may still be possible, depending on your hosting setup to debug remotely if you can set up XDebug on the PHP install, and the host's firewall will allow you to open up that port etc. But before you go down that path, try debug output statements throughout the code)

Have a look at the docs on Debugging. Particularly, Debug::show($myVariable) and Debug::message("My message").

Note though you'll have to take care to revert to the original code once you've sorted out the issue.

Go to Top