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've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Data Model Questions /

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

Migrating SiteTree


Go to End


2 Posts   990 Views

Avatar
Dorsai

Community Member, 12 Posts

15 June 2016 at 5:56pm

Hi,

Having an interesting problem.

We are migrating rows into the SiteTree table from a SiteTree table from another site.

The problem we are having is that the Content field causes the $page->write() to fail.

Every other field comes across ok if we exclude the Content field.

I would assume that because the data is coming from another SilverStripe site that it should be acceptable. We have tried updating the created row with the Content data separately with a SQL query (after the write() command) but that does not work either.

Is there some rules around inserting Content data that I am not aware of? Or some function that will clean/format the data?

Cheers
Hugh

Avatar
Dorsai

Community Member, 12 Posts

16 June 2016 at 9:51am

Just realised I should have given the error generated:
[User Error] Uncaught Exception: Object->__call(): the method 'getelementsbytagname' does not exist on 'SS_HTML5Value'