<?php
- if($source["reference"])
- { $groupe = array
- ( "nom" => $source["reference"]["auteur"],
- "url" => $source["reference"]["from"]
- );
- }
- else
- { $groupe = $data->get_admin_groupe($source["groupes"]);
- if($groupe) $groupe["url"] = $this->url("sources/groupe/view", array("id" => $groupe["id"]));
- }
+ $groupes = $data->get_editor_groupes($source["reference"] ? $source["reference"]["groupes"] : $source["groupes"]);
+ foreach($groupes as $k => $groupe) $groupes[$k]["url"] = $this->url("sources/groupe/view", array("id" => $groupe["id"]));
?>
-
- <h5>
-
-<?php if($groupe) : ?><a class="auteur" href="<?php echo $groupe["url"] ?>"><?php echo $groupe["nom"] ?></a><?php endif; ?>
-
-<?php if(!isset($display_name) || $display_name) : ?>
-
-<?php if($source["reference"]) : ?>
- <span>référence » <a href="<?php echo $source["reference"]["from"] ?>"><strong><?php echo $source["reference"]["titre"] ?> (<?php echo $groupe["nom"] ?>)</strong></a></span>
-<?php else : ?>
+<header>
+
+ <?php if($groupes) : ?>
+ <ul class="authors">
+ <?php foreach($groupes as $groupe) : ?>
+ <li><a class="auteur" href="<?php echo $groupe["url"] ?>"><?php echo $groupe["nom"] ?></a></li>
+ <?php endforeach; ?>
+ </ul>
+ <?php endif; ?>
+ <?php if(!isset($display_name) || $display_name) : ?>
+ <?php
+
+ $HAS_IMAGE = false;
+ if
+ ( $source["image_uri"]
+ && file_exists($source["image_uri"])
+ && ($img_size = $data->img_size($source["image_uri"], 100, 100)) !== false
+ ) :
+ $source_image_uri = $this->path("web").$source["image_uri"];
+ $HAS_IMAGE = true;
+
+ ?>
+ <p class="logo_source">
+ <a href="<?php echo $source["reference"] ? $source["reference"]["from"] : $source["url"] ?>">
+ <img src="<?php echo $source_image_uri ?>"
+ width="<?php echo $img_size["width"] ?>"
+ height="<?php echo $img_size["height"] ?>"
+ alt="" />
+ </a>
+ </p>
+ <?php endif; ?>
+ <h1<?php if($HAS_IMAGE): ?> class="with_image"<?php endif; ?>>
+ <?php if($source["reference"]) : ?>
+ <span>référence » <a href="<?php echo $source["reference"]["from"] ?>"><strong><?php echo $source["reference"]["titre"] ?></strong></a></span>
+ <?php else : ?>
<a href="<?php echo $source["url"] ?>"><?php echo $source["titre"] ?></a>
-<?php endif; ?>
-<?php if($source["derivations"]) : ?>
+ <?php endif; ?>
+ <?php if($source["derivations"]) : ?>
<br />
<span class="small">
dérive de »
-<?php $n = 0; foreach($source["derivations"] as $derivation) : ?>
- <?php echo $n ? ", " : "" ?><a href="<?php echo $derivation["from"] ?>"><strong><?php echo $derivation["titre"] ?> (<?php echo $derivation["auteur"] ?>)</strong></a>
-<?php $n++; endforeach; ?>
+ <?php $n = 0; foreach($source["derivations"] as $derivation) : ?>
+ <?php echo $n ? ", " : "" ?><a href="<?php echo $derivation["from"] ?>"><strong><?php echo $derivation["titre"] ?></strong></a>
+ <?php $n++; endforeach; ?>
</span>
-<?php endif; ?>
+ <?php endif; ?>
+ </h1>
+ <?php endif; ?>
+
+ <br class="clear" />
-<?php endif; ?>
- <br class="clear" />
- </h5>
+</header>
- <div class="player_progress">
- <div class="loaded"><!-- --></div>
- <div class="position"><!-- --></div>
- </div>
+<div class="player_progress">
+ <div class="loaded"><!-- --></div>
+ <div class="position"><!-- --></div>
+</div>