Ruslan Skripka wrote:

Hi, guys.

I stuck on getting n-th article from topic.

I have a topic with huge amount of articles.

I want only number 30 to 50 articles for example.

Can I do that using midgard API, without getting down to mysql layer?

if ($list = mgd_list_topic_articles($topic_id)) { $i = 0; while ($list->fetch()) { if ($i++ < 30) { continue; }

        if ($i > 50) {
            break;
        }

        echo $list->title."<br>\n";
    }
    unset($list, $i);
}


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to