Jump to content

Error message "Invalid value sent to Page::setTemplate" when trying to add or delete repeaters


CliffG
 Share

Recommended Posts

Hi,

I know that similar postings have been made, but the discussions and the code therein were way over my head.

Here's my problem:

I created a website on my local machine that used repeater fields. Everything worked. I transferred it to the dev server online using the Export Site Profile module. Everything worked there, too. Here my memory is a little murky, but I believe that I added some fields to templates that caused pages with repeaters to generate about 1000 new invisible, system-level pages each time they were edited. (This may be what renobird discussed here: <http://processwire.com/talk/topic/3619-updating-repeaters-via-api-without-removeall/>)

So I fired up phpMyAdmin and manually deleted all those pages -- and probably some that I needed for the repeaters. I cleared the cache. I turned the Repeater inputfield off and on. But now I can neither delete the existing repeater fields in the admin nor create new ones. I tried importing a sql dump of a repeater field from the original system but that didn't solve the problem either.

Can anyone tell me if there's a way to fix this? I really need to use repeater fields for this website.

I've built a few sites with PW and feel quite comfortable with it but I haven't plumbed the depths of the API yet and have only the most rudimentary PHP skills. Even so, it's amazing how much I can get done. But, as you see, it's still possible to get stuck when you go beyond your depth.

Your patience is much appreciated.

Cliff

Link to comment
Share on other sites

Are you getting errors when trying to delete or add new repeater fields, or is just nothing happening? Sorry - you show the error in the subject :)

I really haven't used repeater fields much at all, but if you are having problems deleting existing fields, you can do that through PMA as well.

I wouldn't recommend deleting anything through PMA generally, but since you have already ventured in there and deleted all those pages, it sounds like that might have broken some things already anyway.

Go into the "fields" table and delete the appropriate lines as well as deleting the "field_fieldname" tables.

Or if you are cautious, wait for a more authoritative answer :)

  • Like 2
Link to comment
Share on other sites

Adrian,

I'm getting errors when I try to delete existing repeater fields or add new ones.

I wouldn't recommend deleting anything through PMA generally, but since you have already ventured in there and deleted all those pages, it sounds like that might have broken some things already anyway.

I'm pretty sure this is what happened.

Go into the "fields" table and delete the appropriate lines as well as deleting the "field_fieldname" tables.

Or if you are cautious, wait for a more authoritative answer

I'll take a look but given the damage I already did, I may way for more answers. Thank you very much for yours!

Cliff

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...