[support] Saving a node programmatically

Jason Flatt drupal at oadaeh.net
Sat Sep 17 16:27:36 UTC 2011


For Drupal 7, I'm attempting to create a new node and save it in code.  It was
working at one time, but now is not and I cannot figure out what it is I did
to break it.

The node object appears to be correct both before and after the save.

The node gets created and saved in the database, but only the title is saved
with it.  None of the data for the body or any of the custom fields gets saved.

I've been over the code a hundred times, tweaking this and that.  I've
reviewed a.d.o, blog postings, tutorials and various code, and I can't figure
out what I've done wrong.

The code is here: http://drupalbin.com/19810

Thank you for any help or pointers anyone can offer me.


-- 
Jason Flatt
Custom Website development solutions: http://www.oadaeh.net/
Father of seven: http://www.flattfamily.com/ (Joseph, 18; Cramer, 16; Travis,
14; Angela; Harry, 11; William, 5; and Dolly, 3) Linux user:
http://www.ubuntu.org/ Android user: http://www.android.com/
Drupal fanatic: http://drupal.org/


More information about the support mailing list