Solved

the posts are ASC how i can change  the posts sort to desc

Posted on 2008-06-25
5
281 Views
Last Modified: 2013-12-12
Dear experts
i use the wordpress , i notes that the posts sorts are ASC  the first posts appear first , how i can change the sort to be desc  (last post first) , i enterd to the setting and change the appearance of the posts but it still show me the first posts first , i think there is some change on the PHP code .

thank u
0
Comment
Question by:faresahmad
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
5 Comments
 
LVL 6

Expert Comment

by:mmarth
ID: 21866842
krsort($array);
0
 
LVL 15

Accepted Solution

by:
dosth earned 500 total points
ID: 21915528
wp-includes\classes.php

line 564 or some thing

if ((empty($q['order'])) || ((strtoupper($q['order']) != 'ASC') && (strtoupper($q['order']) != 'DESC'))) {
                  $q['order']='ASC';
            }

change that to DESC


if ((empty($q['order'])) || ((strtoupper($q['order']) != 'ASC') && (strtoupper($q['order']) != 'DESC'))) {
                  $q['order']='DESC';
            }
0
 
LVL 15

Expert Comment

by:dosth
ID: 21925891
faresahmad, did you try this?
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Part of the Global Positioning System A geocode (https://developers.google.com/maps/documentation/geocoding/) is the major subset of a GPS coordinate (http://en.wikipedia.org/wiki/Global_Positioning_System), the other parts being the altitude and t…
Since pre-biblical times, humans have sought ways to keep secrets, and share the secrets selectively.  This article explores the ways PHP can be used to hide and encrypt information.
This video teaches users how to migrate an existing Wordpress website to a new domain.
The purpose of this video is to demonstrate how to add AdSense Ads to a WordPress Website, and how to set up WordPress to automatically place Ads in Sidebars. This will be demonstrated using a Windows 8 PC. Log into your AdSense account. : Cli…

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question