Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: Plugin aint working, what am I doing wrong

Hmm it was part of a larger plugin code, took the part out and put it in the plugins folder and it worked here aswell. Problem must be elswhere with the other plugin code.

This results in a new question. My plugin has this code and works:

<?php

// Get Portal topics

function get_portal_topics() {

global $bbdb;

$pforum_id = 1;

$number_of_topics = 10;

return $bbdb->get_results("SELECT * FROM $bbdb->topics WHERE forum_id = $pforum_id ORDER BY topic_time DESC LIMIT 0,$number_of_topics");

}

?>

But I also want to pull the 1 and the 10 from the database $pforum_id = 1; and $number_of_topics = 10; are now manually done…

How to do this then?

Skip to toolbar