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.

All other Modules

Discuss all other Modules here.

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

Website Error After Creating Module


Reply

4 Posts   808 Views

Avatar
BrysaniStudios

21 April 2010 at 9:05am (Last edited: 21 April 2010 9:06am), Community Member, 12 Posts

I was going through this documentation
http://doc.silverstripe.org/doku.php?id=leftandmain&s=leftandmain

I was just trying to get a simple blank module to work so i can start creating it. It was displaying fine from the backend and displayed another tab in the top CMS menu. But being logged out i get the "Website Error - There has been an error...". When I remove the folder from the directory the site works fine. Any Ideas what I might be doing wrong? Or what's some pointers to get it to work?

Avatar
UncleCheese

21 April 2010 at 9:18am 4085 Posts

Make sure your site is in 'dev' mode.

Director::set_environment_type('dev');

Avatar
BrysaniStudios

21 April 2010 at 9:29am Community Member, 12 Posts

Where can I place that code? Also that may fix it temporarily, but i was wondering there were any key things to include when creating a module. I looked through the code in the blog and the userforms modules to see what I could be missing. Not sure why it works when im logged in, but when im logged out, it doesn't work

Avatar
UncleCheese

21 April 2010 at 9:46am 4085 Posts

You'll only know what is wrong if you turn on your error reporting. Put that line in your config.