<?php
  require_once "/var/www/vhosts/richard-riahi.com/httpdocs/cms/lib/viewer_functions.php";
  
  list($interventionsRecords, $interventionsMetaData) = getRecords(array(
    'tableName'   => 'interventions',
    'where'       => whereRecordNumberInUrl(1),
    'limit'       => '1',
  ));
  $interventionsRecord = @$interventionsRecords[0]; // get first record
  
   list($imgheaderRecords, $imgheaderMetaData) = getRecords(array(
    'tableName'   => 'imgheader',
    //'where'       => whereRecordNumberInUrl(1),
    //'limit'       => '1',
  ));
  $imgheaderRecord = @$imgheaderRecords[0];

?>
<!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>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<title></title>
<script type="text/javascript" src="js/jquery.js"></script>
<script type="text/javascript" src="js/swfobject.js"></script>
<script type="text/javascript">
//<!--
$(document).ready(function(){
});
//-->
</script>
<link href="css/layerp1.css" rel="stylesheet" type="text/css" media="screen"/>
<link href="css/all.css" rel="stylesheet" type="text/css" />
</head>
<body>

  <!-- This is 'Container_empty_center' -->
  <div id="Layer-1" >

    <!-- This is 'fondblanc_bkgnd' -->
    <div id="Layer-12" >
  
      <!-- This is 'logo_jpeg' -->
      <div id="Layer-18" >
        <img src="images/logo.gif" alt="logo_jpeg" />      </div>

      <!-- This is 'headerimg_jpeg' (small)-->
      <div id="Layer-17" >
        <?php foreach ($imgheaderRecord['small'] as $upload): ?>
          <?php if ($upload['isImage']): ?>
            <img src="<?php echo $upload['urlPath'] ?>" width="<?php echo $upload['width'] ?>" height="<?php echo $upload['height'] ?>" alt="<?php echo $imgheaderRecord['titlesmall'] ?>" />
          <?php endif ?>
        <?php endforeach ?>
      </div>

      <!-- This is 'menu_jpeg' -->
      <div id="Layer-16" ><img src="images/menu-horizontal.gif" alt="menu_jpeg" border="0" usemap="#Map" />
      <map name="Map" id="Map22">
            <area shape="rect" coords="774,9,849,36" href="actualites-liste.php" />
            <area shape="rect" coords="634,9,773,36" href="questions-frequentes-liste.php" />
            <area shape="rect" coords="543,9,630,36" href="deontologie.php" />
            <area shape="rect" coords="444,9,538,36" href="consultation.php" />
            <area shape="rect" coords="341,9,435,36" href="interventions.php" />
            <area shape="rect" coords="253,9,331,36" href="#" />
            <area shape="rect" coords="167,9,245,36" href="#" />
            <area shape="rect" coords="8,9,161,37" href="docteur.php" />
          </map>

      </div>

      <!-- This is 'headerright_bckgnd' -->
      <div id="Layer-13" ><!-- This is '0590 83 47 02_text' -->
        <div id="Layer-15" >
      <span class="txtHeader">0590 83 47 02</span>
        </div>

        <!-- This is 'chrir_text' -->
        <div id="Layer-14" >
      <span class="txtHeader">CHIRURGIE ESTHETIQUE & REPARATRICE</span>
        </div>
      </div>
    </div>

    <!-- This is 'Container_empty' -->
    <div id="Layer-2" >
  
      <!-- This is 'top_relative' -->
      <div class="Layer-11" ></div>

      <!-- This is 'middle_relative_bkgnd' -->
      <div class="Layer-9" >
    
        <!-- This is 'body_text_relative' -->
        <div class="Layer-10" >
    		<span class="titre"><?php echo $interventionsRecord['nom'] ?></span>
    		<br /><br />
            <!-- PDF -->
        <?php foreach ($interventionsRecord['pdf'] as $upload): ?>
            <div align="right"><img src="images/pdf-ico.gif" alt="Télécharger en PDF la fiche d'information pour &quot;<?php echo $interventionsRecord['nom'] ?>&quot;" width="32" height="32" border="0" align="absmiddle" /><span class="lien_PDF"><a href="<?php echo $upload['urlPath'] ?>"> Télécharger la fiche d'information</a></span></div>
            <br/>
        <?php endforeach ?>
      		<span class="texteNormal"><?php echo $interventionsRecord['description'] ?></span>
            <table width="500" border="0" cellspacing="4" cellpadding="4">
  				<tr>
    				<td align="center" valign="top">
                    	<div align="center">
                        <!-- 'img1' -->
        				<?php foreach ($interventionsRecord['img1'] as $upload): ?>
          				<?php if ($upload['hasThumbnail']): ?>
            			<img class="imgIntervention" src="<?php echo $upload['thumbUrlPath'] ?>" width="<?php echo $upload['thumbWidth'] ?>" height="<?php echo $upload['thumbHeight'] ?>" alt="" /><br/>

          				<?php elseif ($upload['isImage']): ?>
            			<img src="<?php echo $upload['urlPath'] ?>" width="<?php echo $upload['width'] ?>" height="<?php echo $upload['height'] ?>" alt="" /><br/>
                        <?php echo $upload['info1'] ?>
						<?php else: ?>
            			<a href="<?php echo $upload['urlPath'] ?>">Download <?php echo $upload['filename'] ?></a><br/>
     				    <?php endif ?>
        				<?php endforeach ?>                        </div>                    </td>
    				<td align="center" valign="top">
                    	<div align="center">
                        <!--'img2'-->
                        <?php foreach ($interventionsRecord['img2'] as $upload): ?>
          				<?php if ($upload['hasThumbnail']): ?>
            			<img class="imgIntervention" src="<?php echo $upload['thumbUrlPath'] ?>" width="<?php echo $upload['thumbWidth'] ?>" height="<?php echo $upload['thumbHeight'] ?>" alt="" /><br/>
          				<?php elseif ($upload['isImage']): ?>
            			<img src="<?php echo $upload['urlPath'] ?>" width="<?php echo $upload['width'] ?>" height="<?php echo $upload['height'] ?>" alt="" /><br/>
          				<?php else: ?>
            			<a href="<?php echo $upload['urlPath'] ?>">Download <?php echo $upload['filename'] ?></a><br/>
          				<?php endif ?>
        				<?php endforeach ?>                        </div>                    </td>
    				<td align="center" valign="top">
                    	<div align="center">
                    	<?php foreach ($interventionsRecord['img3'] as $upload): ?>
          				<?php if ($upload['hasThumbnail']): ?>
            			<img class="imgIntervention" src="<?php echo $upload['thumbUrlPath'] ?>" width="<?php echo $upload['thumbWidth'] ?>" height="<?php echo $upload['thumbHeight'] ?>" alt="" /><br/>
          				<?php elseif ($upload['isImage']): ?>
            			<img src="<?php echo $upload['urlPath'] ?>" width="<?php echo $upload['width'] ?>" height="<?php echo $upload['height'] ?>" alt="" /><br/>
          				<?php else: ?>
            			<a href="<?php echo $upload['urlPath'] ?>">Download <?php echo $upload['filename'] ?></a><br/>
          				<?php endif ?>
        				<?php endforeach ?>                    	</div>                    </td>
  				    <td align="center" valign="top"><div align="center"><?php foreach ($interventionsRecord['img4'] as $upload): ?>
          				<?php if ($upload['hasThumbnail']): ?>
            			<img class="imgIntervention" src="<?php echo $upload['thumbUrlPath'] ?>" width="<?php echo $upload['thumbWidth'] ?>" height="<?php echo $upload['thumbHeight'] ?>" alt="" /><br/>
          				<?php elseif ($upload['isImage']): ?>
            			<img src="<?php echo $upload['urlPath'] ?>" width="<?php echo $upload['width'] ?>" height="<?php echo $upload['height'] ?>" alt="" /><br/>
          				<?php else: ?>
            			<a href="<?php echo $upload['urlPath'] ?>">Download <?php echo $upload['filename'] ?></a><br/>
          				<?php endif ?>
        				<?php endforeach ?>                    	</div></td>
  				</tr>
			</table>
            <br />
            <br />
          <span class="lien_interventionBack"><a href="javascript:history.go(-1)">&lt;&lt; Retour vers la liste des interventions pour "<?php echo $interventionsRecord['categorie'] ?>"</a></span><br/>
      <!-- Pas de fiche -->
    <?php if (!$interventionsRecord): ?>
      <span class="texteNormal">Aucune fiche trouvée</span><br/><br/>
    <?php endif ?>
        </div>
      </div>

      <!-- This is 'fondblanc_bkgnd_relative' -->
      <div class="Layer-3" >
    
        <!-- This is 'fond_bkgnd' -->
        <div id="Layer-7" >
      
          <!-- This is 'coordonnees_text' -->
          <div id="Layer-8" >
            <span class="lien_FooterLeft"><a href="mailto:contact@richard-riahi.com">contact@richard-riahi.com</a></span><br />
            <span class="txtFooterLeft">0590 83 47 02</span>
            </div>
        </div>

        <!-- This is 'fond_bkgnd' -->
        <div id="Layer-4" >
      
          <!-- This is 'adresse2_text' -->
          <div id="Layer-6" >
        <span class="txtFooterRight">Centre ESTHETIS<br />
		Morne Bernard Moudong Nord<br />
		97122 Baie-Mahault</span>
          </div>

          <!-- This is 'adresse1_text' -->
          <div id="Layer-5" >
        <span class="txtFooterRight">Rédidence Morne Flory<br />
        301 Boulevard des Héros<br />
		97110 Pointe-à-Pitre</span>
          </div>
        </div>
      </div>
    </div>
  </div>
</body>
</html>
