<?php
  
  require_once "cmsAdmin/lib/viewer_functions.php";

  list($pagesRecords, $pagesMetaData) = getRecords(array(
    'tableName'   => 'pages',
	'where'       => 'depth <=2',
    'limit'       => '12',
	
    
  ));

?>
 <?php foreach ($pagesRecords as $record): ?>
     
         
       <a href="viewPages.php?recordID=<?php echo $record['num'] ?>"><?php echo join(', ', getListLabels('pages', 'links', $pagesRecord['links'])); ?><?php echo $record['name'] ?></a><br/><br />


  <?php endforeach ?>