Trying to change the Text Format on a Field for a Content Type will not change from Basic HTML. Once saved, it reverts back to Basic HTML. Can this not be changed after creation?

Comments

VM’s picture

Yes this can be changed in a default install. a dev of a clean install helps sort out these types of questions. Doesn't sound like the database is properly updating the change.

Rewted’s picture

Well, this is a Content Type which was part of a D6 to D8 migration. Any suggestions on how to address the issue?

VM’s picture

I'd review the known issues listed under text formats @ https://www.drupal.org/docs/8/upgrade/known-issues-when-upgrading-from-d... to see if your issue relates.

Rewted’s picture

Good idea. I did see the format_null issue after import, but do not recall if it affected the Text Format I want to use now. One suggested solution is to change to another input format. This suffers the same problems as the previous point, but that would require me modifying 100+ articles each with at least 10 of these fields, by hand! :(

Perhaps I'll just leave things as is.

VM’s picture

but that would require me modifying 100+ articles each with at least 10 of these fields, by hand!

I'd write a query to adjust directly in the DB.

Rewted’s picture

Yikes. I don't feel comfortable doing that, don't know much about DB manipulation.

VM’s picture

seems like a perfect time to learn on a back up of the DB.

Rewted’s picture

So I found the field (field_car_format) in the DB with current value "NULL". Can I simply do this?

update `node__field_car` set field_car_format ='text_plain';

Or, can I just delete the field_car_format all together and the Text format will default to Plain Text as nothing would be assigned?

Rewted’s picture

I've modified all occurrences for the field within the Database. When using Drupal 8.2.7 GUI to manage this field, changing from Basic to Full HTML, it still reverts back. Any other suggestions?

adriansolisz’s picture

I'm trying to do exactly the same, changing the format of a specific field and I have almost a week researching on how to do it with no success yet.