child.parts should be an array
> -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of > Saji Njarackalazhikam Hameed > Sent: Wednesday, 16 May 2007 4:57 PM > To: [email protected] > Subject: Re: [Radiant] automated page building > > Sean, > > Thanks.. > > With the URL now enclosed by quotes, I get the following > error ...hmmm. > what could i be doing wrong? > > saji > > # Start of Ruby code > #require 'config/environment' ! i commented this out > > parent = Page.find_by_url("/articles/") > > i=1 > child = Page.new > child.parent = parent > child.title = "Page #{i}" > child.breadcrumb = "Page #{i}" > child.slug = "page-#{i}" > body = PagePart.new > body.content = "This is page #{i}" > child.parts = body > child.save! _______________________________________________ Radiant mailing list Post: [email protected] Search: http://radiantcms.org/mailing-list/search/ Site: http://lists.radiantcms.org/mailman/listinfo/radiant
