In the content.devel.inc file you can find the content_generate_fields function. There's a TODO in the description so somebody might already be working on this.
I'll explain the situation: I have two textfields and one filefield (which is an image). Everytime the function is called to generate content, three images are generated instead of one (on the server and in the files table in the database).
I tried to see if the content would be generated correctly if I got rid of the first loop and that seemed to work..
..
if (!empty($type['fields'])) {
//foreach ($type['fields'] as $field) {
$node_field = array();
..
This might probably only work in my specific situation. Maybe there's someone who has a better solution?
Comment | File | Size | Author |
---|---|---|---|
#2 | cck_1049656_content_generate_fields.patch | 3.3 KB | hefox |
#1 | cck_1049656_content_generate_fields.patch | 40.25 KB | hefox |
Comments
Comment #1
hefox CreditAttribution: hefox commentedRemoved the foreach and seems to work fine so far
Comment #2
hefox CreditAttribution: hefox commentedforgot I had updated cck to see if helped, new patch.
Comment #3
hefox CreditAttribution: hefox commented