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:

All other Modules /

Discuss all other Modules here.

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

Can't load saved newsletter (error loading page)

Go to End

32 Posts   5258 Views

Liquid Edge Creative

Community Member, 56 Posts

30 April 2010 at 1:41pm

Edited: 30/04/2010 1:42pm

I'm having all sorts of nightmares upgrading to 2.4!

Having followed the instructions very carefully, I flushed the database and just got a generic error message. I added the line Director::set_environment_type("dev"); to my _config.php file to get some more info on the error, but somehow this caused the database to rebuild properly.

I then went to refresh the CMS and got this error message:

[Warning] Missing argument 2 for CheckboxSetWithExtraField::setValue(), called in .../sapphire/forms/FormField.php on line 78 and defined
GET /silverstripe-v2.3.7/admin/?flush=1

Line 237 in .../newsletter/code/CheckboxSetWithExtraField.php

228 $record->$k = Convert::array2json($v);
229 }
230 }
231 } else {
232 $record->$fieldname = '';
233 }
234 }
235 }
237 function setValue($val, $data){
238 if(is_string($val)) {
239 $val = explode(",", $val);
240 }
242 $this->value = $val;

This looks to me like an issue between the new Silverstripe version and the Newsletter module.

If I remove the Newsletter module from my webroot and flush the database I just get a blank white screen.

Any thoughts or solutions?

Thanks kindly for your help.


Community Member, 203 Posts

30 April 2010 at 7:43pm

Do you have userforms installed? You do not need userforms anymore for the new newsletter module and userforms is still at 2.3.x

Do you still have an old subscribe form installed? try removing it temporarily (by dragging it out of the mysite/code folder or removing the php extension)

Flushing the database = ???? (both when removing and installing the newsletter)

I tried on a local install and did not get any errors, could save and edit a draft newsletter. I will try the unsubscribe feature later

Liquid Edge Creative

Community Member, 56 Posts

1 May 2010 at 8:40am

I've tried removing the Userforms module but this hasn't made a difference it would seem. The same error message remains.

When I initially set up Newsletter module in my 2.3.7 version of Silverstripe I discovered quickly on the forums that Userforms was no longer needed so just set up my subscription page with the SubscriptionPage type that comes with Newsletter. This was working fine.

I had tried to do a subscription page with the old Userforms method but this hadn't worked so I'd deleted that page. I can't see any old subscribe forms in my mysite/code folder.

Perhaps I need to start over with a fresh install of Silverstripe 2.4, then copy my Themes and Mysite folders into it? Kinda the opposite workflow to the usual upgrade process.

Do I need to make sure my server is turned off when I drag things in and out of my webroot or is it OK to leave it running during the upgrade process?


Community Member, 203 Posts

1 May 2010 at 12:10pm

you can safely keep your webserver on, np.

Liquid Edge Creative

Community Member, 56 Posts

4 May 2010 at 11:44am

I'm going to try reverting back to my original 2.3.7 install that was working fine (apart from Newsletter issues that prompted my original post).

Then I'll remove Userforms and Newsletter modules, and make sure site is working without them before doing the 2.4 upgrade. If I can get the upgrade working I'll reinstall Newsletter and go from there.

Will let you know how I get on.


Community Member, 137 Posts

13 May 2010 at 6:59pm

I am getting the same error here. I'm on stable 2.4 and are trying to use the newsletter module for the first time. (I've using the daily build version for the newsletter module)

I create a draft email and click save, but then I go to click back and look at the saved draft and I get "error loading page".

Any help would be great


Community Member, 203 Posts

13 May 2010 at 7:53pm


There are some classes that have to be renamed, three in total if I am not mistaken:

SSDateTime should be SS_Datetime
Database should be SS_Database

And then there is one other that specifically causes a problem with the opening and saving of a newsletter draft. I believe it was either HTTPRequest (should be SS_HTTPRequest) or HTTPResponse (should be SS_HTTPResponse), but it could also be another.

It can also be that the first two classes have already been renamed.


Community Member, 137 Posts

14 May 2010 at 2:00pm

yurigoul, thankyou for the response, you have probably saved me from tearing my hair out for the next 8 hours!

2 name changes must be made.

Database to SS_Database


HTTPRequest to SS_HTTPRequest

I've got a ticket open, which I will now fix up with this solution.

Thanks again!