A problem with typecho about the order of articles in the article and how to get a link to the next article in the content page?

150 5

1, the default order of typecho articles is sorted in descending order, and I wanted to change in ascending order, and can be set in the themeInit() method in the functions.php file in the theme? What's the setting variable? or, you can only change the kernel code.

2, content pages,
Last article $this->thePrev()
Next article $this->theNext()
The output contains a label and how to get a simple link address and title title.

1 Answers

83 5

Need to change the kernel.
In the var widget archive. Php function, the function execute line 1257:

/** 仅输出文章 */
 $this->_countSql = clone $select;
 $select->order('table.contents.created', Typecho_Db::SORT_DESC)
 ->page($this->_currentPage, $this->parameter->pageSize);