Alexander Levenetz wrote:
> Now I have several problems. First of all an error message:
>
> Parse error: parse error in ROOT on line 3
>
> line 3 would be: $topic_id = 26;
Are you sure this is in your ROOT element? It can be of course but
I don't usually see it this way. Can I see the content of your
root element?
> Then this whole construction shows only 3 lines (= 3 articles/topics)
> and it lists stuff that is old, very old. Actually the only new thing
> that is listed comes from my root (26). That's ok, it should be listed
> on top anyway. But I need four lines and in the 2nd it should show the
> newest stuff from 28, in the 3rd from 59 and in the fourth from 62.
> Content from 62 is not shown at all. I really don't know what's going
> on there.
> Here's the whole construct:
>
> <?
> $showlist = array();
Leave out this part for a moment
> $article = mgd_list_topic_articles_all($topic_id); $displayed = 0;
> --------- was 26 before, but
> doesn't change anything, of
> course.
>
> while ($displayed == 0 && $article && $article->fetch()) {
> if (mgd_is_article_in_topic_tree(94, $article->id)) { continue; }
> if (mgd_is_article_in_topic_tree(111, $article->id)) { continue; }
> if (mgd_is_article_in_topic_tree(28, $article->id)) { continue; }
> if (mgd_is_article_in_topic_tree(62, $article->id)) { continue; }
> if (mgd_is_article_in_topic_tree(59, $article->id)) { continue; }
>
> $displayed++;
> $showlist[] = $article->id;
> }
because I think the problem will be below. This will narrow down
the search. You could even set the array to be only $topics = array(28)
so we have less ground to cover.
> $topics = array(28, 59, 62); reset ($topics);
> while (list(, $topic) = each ($topics)) {
> $article = mgd_list_topic_articles($topic, "reverse created");
> if ($article && $article->fetch()) { $showlist[] = $article->id; }
> }
>
> reset ($showlist);
> while (list(, $id) = each ($showlist)) {
> $article = mgd_get_article($id);
> ?>
Emile
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]