Tag Cloud in PHP

code :-
<?php

// connect to database at some point

// In the SQL below, change these three things:
// thing is the column name that you are making a tag cloud for
// id is the primary key
// my_table is the name of the database table

$query = “SELECT thing AS tag, COUNT(id) AS quantity
FROM my_table
GROUP BY thing
ORDER BY thing [...]