PDA

View Full Version : Sort Authors by Last Name?


bnjp
07-24-2005, 11:10 PM
Any way to sort authors by last name rather than first name? It seems like last name would be the default, but apparently not.

Jordie (Interspire Staff)
07-25-2005, 04:40 AM
Hi,

Goto the panel folder in your chosen template and locate ViewAuthors.php (plural, there is also a non-plural file there). Locate this code:$query = sprintf("select *, concat(FirstName, ' ', LastName) as Name from %susers where Status=1 %sorder by Name asc", $GLOBALS["AL_CFG"]["tablePrefix"], $ExtraWhere);Then replace with $query = sprintf("select *, concat(FirstName, ' ', LastName) as Name from %susers where Status=1 %sorder by LastName asc", $GLOBALS["AL_CFG"]["tablePrefix"], $ExtraWhere);

Hoep that helps.

bnjp
07-26-2005, 01:58 AM
Hoep that helps.


Tremendously! Thanks. :)