<?php header('Content-type: text/html; charset=utf-8'); ?>
<?php
  /* STEP 1: LOAD RECORDS - Copy this PHP code block near the TOP of your page */
  require_once "/services/webpages/a/x/axislighting.com/public/cmsAdmin/lib/viewer_functions.php";

  
  // remove white space   
  if (@$_REQUEST['name_keyword']) { 
  $_REQUEST['name_keyword'] = str_replace(" ", "", $_REQUEST['name_keyword']);  
  }
  
  list($itemsRecords, $itemsMetaData) = getRecords(array(
    'tableName'   => 'items',
    'where'       => whereRecordNumberInUrl(1),
	    'limit'       => '45',
  ));
 
  $itemsRecord = @$itemsRecords[0]; // get first record
  
  list($distributionRecords, $distributionMetaData) = getRecords(array(
    'tableName'   => 'distribution',
    'where'       => whereRecordNumberInUrl(1),
    'limit'       => '45',
  ));
  $distributionRecord = @$distributionRecords[0]; // get first record
  
  list($brandsRecords, $brandsMetaData) = getRecords(array(
    'tableName'   => 'brands',
    'where'       => whereRecordNumberInUrl(1),
    'limit'       => '45',
  ));
  $brandsRecord = @$brandsRecords[0]; // get first record
  
  list($downloadsRecords, $downloadsMetaData) = getRecords(array(
    'tableName'   => 'downloads',
    'where'       => whereRecordNumberInUrl(1),
    'limit'       => '45',
  ));
 $downloadsRecord = @$downloadsRecords[0]; // get first record

  
 

?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
 <head>
  <title></title>
  <meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
  <style type="text/css">
    body          { font-family: arial; color:#fff;}
    .instructions { border: 3px solid #000; background-color: #EEE; padding: 10px; text-align: left; margin: 25px}
  a:link {
	color: #80a4c3;
}
a:visited {
	color: #80a4c3;
}
a:hover {
	color: #47637c;
}
  .text-12-no-justify-search {
	font-size: 12px;
	color: #7c93a7;
	font-family: Arial, Helvetica, sans-serif;
	line-height: 16px;
}
  </style>
 <link href="axis.css" rel="stylesheet" type="text/css" />
 </head>
<body>
  <?php include("header.php"); ?>
 
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td height="18"></td>
  </tr>
  <tr>  
    <td height="30" bgcolor="#16191e"><div class="breadcrumbs">Products >> Search Results </div></td>
   </tr>
  <tr>
    <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td height="500" valign="top" bgcolor="#2d343d"><!-- STEP2: Display Records (Paste this where you want your records to be listed) -->
          <table align="left" cellpadding="2" cellspacing="2" class="margin-table-search-results">
            <tr>  <?php foreach ($itemsRecords as $record): ?>     
              <td width="168" align="left"> 
                <?php foreach ($record['main_image'] as $upload): ?>
                
                
                <?php if ($upload['isImage']): ?>
  <a href="<?php echo $record['link'] ?>"><img src="<?php echo $upload['urlPath'] ?>" alt="" class="img-bord" width="150" height="150" border="0" /></a>     <?php endif ?>
                <?php endforeach ?>
                <table width="150" cellpadding="0" cellspacing="0">
                  <tr>
                    <td colspan="2" height="3"></td>
                    </tr>
                  <tr>
                    <td>
                      <?php foreach ($record['small_logo'] as $upload): ?>
                      <a href="<?php echo $record['link'] ?>">
                        <img src="<?php echo $upload['urlPath'] ?>" alt="<?php echo $record['name'] ?>" border="0">
                        </a>
                      <?php endforeach ?>
                      </td>
                    <td align="right" valign="bottom">
                      <span class="text-12-no-justify-search">
                        <?php echo $record['mounting'] ?>
                        </span>
                      </td>
                    </tr>
                  <tr>
                    <td height="15"></td>
                    </tr>
                  </table>
                </td>  
              <?php $maxCols=6; if (@++$count % $maxCols == 0): ?>  </tr>  <tr>  <?php endif ?>  <?php endforeach ?>  </table>
          
          <?php if (!$itemsRecords): ?>
    <br/><div class="text-12-no-justifyWhite">No records were found! Please try again.</div><br/><br/>
    <?php endif ?>
</tr>
    </table>

</tr>
    </table></td>
  </tr>
  <tr>
    <td> 
  <!-- /STEP2: Display Records -->

</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
  </tr>
</table> <?php include("footer.php"); ?>
</body>
</html>
