- // Referal levels
- $result = SQL_QUERY("SELECT id, url, alternate, visible, counter, clicks FROM `{!_MYSQL_PREFIX!}_refbanner` ORDER BY url",
- __FILE__, __LINE__);
- if (SQL_NUMROWS($result) > 0) {
- // Make referal banner editable and deletable
- $OUT = ''; $SW = 2;
- while ($content = SQL_FETCHARRAY($result)) {
- // Preapre data for the row
- // @TODO Rewritings: alt->alternate,cnt->counter,clx->clicks in template
- $content = array(
- 'sw' => $SW,
- 'id' => $content['id'],
- 'url' => $content['url'],
- 'alt' => $content['alternate'],
- 'vis' => TRANSLATE_YESNO($content['visible']),
- 'cnt' => $content['counter'],
- 'clx' => $content['clicks']
- );
+ // Referral levels
+ $result = sqlQuery('SELECT `id`, `url`, `alternate`, `visible`, `counter`, `clicks` FROM `{?_MYSQL_PREFIX?}_refbanner` ORDER BY `url` ASC', __FILE__, __LINE__);