integration jaudio-player
[mw_sourceml] / app / out / default / views / sources / source / documents.php
1 <?php
2
3   $documents = $source["reference"] ? $source["reference"]["documents"] : $source["documents"];
4   if($documents) :
5   $mw_out = $this->helper("mw_helper_out");
6
7 ?>
8
9
10   <ul class="documents">
11     <?php foreach($documents as $id_document => $document) : ?>
12     <li id="document_<?php echo $source["id"]."_".$id_document ?>">
13       <?php
14         if(!($nom = $document["nom"])){
15           $nom = explode(".", $document["url"]);
16           if(count($nom) > 1) $nom = $nom[count($nom) - 1];
17           else $nom = $document["url"];
18           if(strlen($nom) > 16) $nom = "(...) ".substr($nom, -16);
19         }
20       ?>
21       <a href="<?php echo $document["url"] ?>" title="<?php echo $mw_out->esc_attr($document["nom"]); ?>"><?php echo $nom; ?></a>
22     </li>
23     <?php endforeach; ?>
24   </ul>
25   <div class="clear"><!-- --></div>
26
27 <?php endif; ?>