Pages

Ascending and Descending Order in PHP

Hi.this is order by ascending and descending order  to alphabets and number .this   very a simple  to PHP MySQL  .if order by ascending ("ORDER BY FILED_NAME ASC")  or order by descending  ("ORDER BY FILED_NAME DESC") ..,

ORDER BY Ascending


<?php
$select= mysql_query("SELECT * FROM table_name ORDER BY filed_name ASC"); ?>



ORDER BY  Descending


<?php
$select= mysql_query("SELECT * FROM table_name address ORDER BY filed_name DESC");
?>

 filed_name:table filed name exaple id,name ,email and etc....