diff --git a/lib/listlib.php b/lib/listlib.php index d3c89db6b42..75c266d2bdc 100644 --- a/lib/listlib.php +++ b/lib/listlib.php @@ -210,7 +210,7 @@ class moodle_list{ * @return integer $offset + how many toplevel items where there in this list. * */ - function list_from_records($paged = false, $offset =0){ + function list_from_records($paged = false, $offset =1){ $this->paged = $paged; $this->offset = $offset; $this->get_records(); diff --git a/question/category_class.php b/question/category_class.php index 6ab93bb3158..772d3c27e62 100644 --- a/question/category_class.php +++ b/question/category_class.php @@ -138,7 +138,7 @@ class question_category_object { $this->str->page = get_string('page'); $this->pixpath = $CFG->pixpath; - $this->editlist = new question_category_list('ul', '', true, $page, $pageurl, 'cpage'); + $this->editlist = new question_category_list('ul', '', true, $pageurl, $page, 'cpage', QUESTION_PAGE_LENGTH); $this->pageurl = $pageurl; @@ -177,7 +177,7 @@ class question_category_object { error("Error: Could not find or make a category!"); } - $this->editlist->list_from_records(QUESTION_PAGE_LENGTH); + $this->editlist->list_from_records(); $this->categories = $this->editlist->records;