I noticed that when one performs a search or clicks on a tag, the results are automatically sorted oldest to newest. I want this to be the reverse. So I opened up libs/search.php and found this code:
PHP Code:
if(isset($this->orderBy)){
if(strpos($this->orderBy, "RDER BY") != 1){
$this->orderBy = "ORDER BY " . $this->orderBy;
}
}
I then added an else clause like this:
PHP Code:
if(isset($this->orderBy)){
if(strpos($this->orderBy, "RDER BY") != 1){
$this->orderBy = "ORDER BY " . $this->orderBy;
}
}else{
// Add a default order by clause, newest to oldest.
$this->orderBy = "ORDER BY link_published_date DESC";
}
But it still sorts oldest to newest. Any ideas why this clause isn't taking effect?
David.