Re: [Phpslash-devel] story import
Brought to you by:
joestewart,
nhruby
From: Luis M <le...@gm...> - 2004-10-06 05:29:04
|
Sorry i use the term "addstory" instead of "newstory" (from Story_admin.class). But in any case, you need to use "savestory" from Story_base.class (include/modules/story directory). Essentially, you could simply do: Starting from line 676, these are the variables you will need in an $array: $q = "INSERT INTO psl_story (story_id, user_id, title, order_no, dept, intro_text, body_text, date_available, hits, topic_cache, story_options) VALUES ('$ary[story_id]', '$ary[author_id]', '$ary[title]', '$ary[order_no]', '$ary[dept]', '$ary[intro_text]', '$ary[body_text]', $ary[timestamp], '0', '', '$serial_opts')"; // debug("Story_base::saveStory: insert query",$q); $this->db->query($q); $cmtcount = "INSERT INTO psl_commentcount (count_id, count) VALUES ('$ary[story_id]', 0)"; ... The psl documentation for developers could help you further. I know there is a link for it in php-slash.org, but I don't recall it. In any case, there is a .sgml file inside the "doc" directory that contains the information you need. On Wed, 06 Oct 2004 01:11:16 -0400, Matt Wiseman <tro...@sh...> wrote: > You got any documentation on the addstory() call? > > > On Tue, 2004-10-05 at 09:28, Luis M wrote: > > >I'm running the latest version of slash and am trying to import stories > > >from another system into it. > > >I can pull stories no problem, but if I just insert them into > > >psl_stories everything breaks. What's the proper way for me to do this? -- ----)(----- Luis M System Administrator LatinoMixed.com "We think basically you watch television to turn your brain off, and you work on your computer when you want to turn your brain on" -- Steve Jobs in an interview for MacWorld Magazine 2004-Feb No .doc: http://www.fsf.org/philosophy/no-word-attachments.es.html |