You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

96 lines
3.8 KiB

14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
14 years ago
  1. <?php
  2. /**
  3. * DokuWiki Image Detail Page
  4. *
  5. * @author Andreas Gohr <andi@splitbrain.org>
  6. * @author Anika Henke <anika@selfthinker.org>
  7. */
  8. // must be run from within DokuWiki
  9. if (!defined('DOKU_INC')) die();
  10. @require_once(dirname(__FILE__).'/tpl_functions.php'); /* include hook for template functions */
  11. ?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  12. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  13. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $conf['lang']?>"
  14. lang="<?php echo $conf['lang']?>" dir="<?php echo $lang['direction'] ?>">
  15. <head>
  16. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  17. <title>
  18. <?php echo hsc(tpl_img_getTag('IPTC.Headline',$IMG))?>
  19. [<?php echo strip_tags($conf['title'])?>]
  20. </title>
  21. <?php tpl_metaheaders()?>
  22. <meta name="viewport" content="width=device-width,initial-scale=1" />
  23. <?php echo tpl_favicon(array('favicon', 'mobile')) ?>
  24. <?php _tpl_include('meta.html') ?>
  25. </head>
  26. <body>
  27. <!--[if IE 6 ]><div id="IE6"><![endif]--><!--[if IE 7 ]><div id="IE7"><![endif]--><!--[if IE 8 ]><div id="IE8"><![endif]-->
  28. <div id="dokuwiki__detail" class="dokuwiki">
  29. <?php html_msgarea() ?>
  30. <?php if($ERROR){ print $ERROR; }else{ ?>
  31. <h1><?php echo hsc(tpl_img_getTag('IPTC.Headline',$IMG))?></h1>
  32. <div class="content">
  33. <?php tpl_img(900,700) ?>
  34. <div class="img_detail">
  35. <h2><?php print nl2br(hsc(tpl_img_getTag('simple.title'))); ?></h2>
  36. <dl>
  37. <?php
  38. $config_files = getConfigFiles('mediameta');
  39. foreach ($config_files as $config_file) {
  40. if(@file_exists($config_file)) {
  41. include($config_file);
  42. }
  43. }
  44. foreach($fields as $key => $tag){
  45. $t = array();
  46. if (!empty($tag[0])) {
  47. $t = array($tag[0]);
  48. }
  49. if(is_array($tag[3])) {
  50. $t = array_merge($t,$tag[3]);
  51. }
  52. $value = tpl_img_getTag($t);
  53. if ($value) {
  54. echo '<dt>'.$lang[$tag[1]].':</dt><dd>';
  55. if ($tag[2] == 'date') {
  56. echo dformat($value);
  57. } else {
  58. echo hsc($value);
  59. }
  60. echo '</dd>';
  61. }
  62. }
  63. ?>
  64. </dl>
  65. <?php //Comment in for Debug// dbg(tpl_img_getTag('Simple.Raw'));?>
  66. </div>
  67. <div class="clearer"></div>
  68. </div><!-- /.content -->
  69. <p class="back">
  70. <?php
  71. $imgNS = getNS($IMG);
  72. $authNS = auth_quickaclcheck("$imgNS:*");
  73. if (($authNS >= AUTH_UPLOAD) && function_exists('media_managerURL')) {
  74. $mmURL = media_managerURL(array('ns' => $imgNS, 'image' => $IMG));
  75. echo '<a href="'.$mmURL.'">'.$lang['img_manager'].'</a><br />';
  76. }
  77. ?>
  78. &larr; <?php echo $lang['img_backto']?> <?php tpl_pagelink($ID)?>
  79. </p>
  80. <?php } ?>
  81. </div>
  82. <!--[if ( IE 6 | IE 7 | IE 8 ) ]></div><![endif]-->
  83. </body>
  84. </html>