Location: PHPKode > projects > Esvon Personals > esvon-personals/modules/Reviews/addons/blocks/Ad_Row/block-Reviews.php
<?php

// --------------------------------------------------------------------------
//
// Esvon Classifieds v.4.0
// Copyright(C), Esvon LTD, 2001-2010, All Rights Reserved.
// E-mail: hide@address.com
//
// All forms of reproduction, including, but not limited to, internet posting, 
// printing, e-mailing, faxing and recording are strictly prohibited.
// One license required per site running Esvon Classifieds. 
// To obtain a license for using Esvon Classifieds, please register at
// http://www.esvon.com/pg/products/p_classifieds/
//
// --------------------------------------------------------------------------

function block_Ad_Row_Reviews(&$tpl){
  
  global $db,$A_LID,$a_Ad;
  static $A_REVIEW;
  
  if (!isset($A_REVIEW)) {
    $A_REVIEW = $db->two_col_assoc('SELECT link_id, COUNT(id) FROM '.hwModTable('Reviews','data').
      ' WHERE link_id IN ('.implode(',',$A_LID).') AND approved="1" GROUP BY link_id');
  }
  
  $v['rev_num'] = $A_REVIEW[$a_Ad['link_id']];
  if (!$v['rev_num']) $v['rev_num']=0;
  $tpl->AddCell('b_Reviews',$v);
  
}

?>
Return current item: Esvon Personals