Mark Milbourne
Mark Milbourne

Reputation: 141

Drupal CCK Text field not saving

I've been trying to write a CCK Field based on the Text field. But if I create a standard CCK Text field with only 1 value. Then edit a content item for this type, the values are never persisted. When I go back in and edit the same node, the value isn't there. I checked the database and its not in the table for the CCK node.

If I use more than one value it works fine.

I'm upto date on CCK (6.x-2.6) and CTools (6.x-1.5).

Has anyone seen this? and a possible solution?

Upvotes: 1

Views: 1389

Answers (1)

Mark Milbourne
Mark Milbourne

Reputation: 141

So I found the problem after a long debugging session. It turns out that there is a bug in the Embedded Media module. They had set not allowing nulls in the database table, but the module was passing nulls. Mysql didn't like this and was complaining about it, and didn't make any updates to that particular node. What made it worse was that I had the error messages turned off, so I wasn't seeing the errors.

The solution was to set the table to allow nulls, now its working fine.

Upvotes: 4

Related Questions