linkinfo.php 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. <?php
  2. /**
  3. * Insipid
  4. * Personal web-bookmark-system
  5. *
  6. * Copyright 2016-2021 Johannes Keßler
  7. *
  8. * Development starting from 2011: Johannes Keßler
  9. * https://www.bananas-playground.net/projekt/insipid/
  10. *
  11. * creator:
  12. * Luke Reeves <luke@neuro-tech.net>
  13. *
  14. * This program is free software: you can redistribute it and/or modify
  15. * it under the terms of the GNU General Public License as published by
  16. * the Free Software Foundation, either version 3 of the License, or
  17. * (at your option) any later version.
  18. *
  19. * This program is distributed in the hope that it will be useful,
  20. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  21. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  22. * GNU General Public License for more details.
  23. *
  24. * You should have received a copy of the GNU General Public License
  25. * along with this program. If not, see http://www.gnu.org/licenses/gpl-3.0.
  26. *
  27. */
  28. ?>
  29. <section class="section">
  30. <div class="columns">
  31. <?php require('_headNavIcons.inc.php'); ?>
  32. </div>
  33. <div class="columns">
  34. <div class="column">
  35. <h1 class="is-size-2"><?php echo $linkData['title']; ?></h1>
  36. </div>
  37. </div>
  38. </section>
  39. <section class="section">
  40. <div class="columns">
  41. <div class="column is-one-third">
  42. <p><?php echo $T->t('view.title'); ?></p>
  43. </div>
  44. <div class="column is-two-third">
  45. <p><?php echo $linkData['title']; ?></p>
  46. </div>
  47. </div>
  48. <div class="columns">
  49. <div class="column is-one-third">
  50. <p><?php echo $T->t('view.description'); ?></p>
  51. </div>
  52. <div class="column is-two-third">
  53. <p><?php echo $linkData['description']; ?></p>
  54. </div>
  55. </div>
  56. <div class="columns">
  57. <div class="column is-one-third">
  58. <p><?php echo $T->t('view.url'); ?></p>
  59. </div>
  60. <div class="column is-two-third">
  61. <p><a href="<?php echo $linkData['link']; ?>" target="_blank"><?php echo $linkData['link']; ?></a></p>
  62. </div>
  63. </div>
  64. <div class="columns">
  65. <div class="column is-one-third">
  66. <p>
  67. <?php echo $T->t('view.image'); ?> (<small><?php echo $T->t('view.image.provided'); ?></small>)
  68. </p>
  69. </div>
  70. <div class="column is-two-third">
  71. <p>
  72. <img class="linkthumbnail" src="<?php echo $linkData['imageToShow']; ?>" alt="<?php echo $T->t('view.image.provided'); ?>">
  73. </p>
  74. </div>
  75. </div>
  76. <div class="columns">
  77. <div class="column is-one-third">
  78. <p><?php echo $T->t('view.date.added'); ?></p>
  79. </div>
  80. <div class="column is-two-third">
  81. <p><?php echo $linkData['created']; ?></p>
  82. </div>
  83. </div>
  84. <div class="columns">
  85. <div class="column is-one-third">
  86. <p><?php echo $T->t('view.tags'); ?></p>
  87. </div>
  88. <div class="column is-two-third">
  89. <?php
  90. if(!empty($linkData['tags'])) {
  91. foreach($linkData['tags'] as $k=>$v) {
  92. ?>
  93. <a href="index.php?p=overview&m=tag&id=<?php echo urlencode($k); ?>" class="button is-small">
  94. <span class="icon"><i class="ion-md-pricetag"></i></span>
  95. <span><?php echo $v; ?></span>
  96. </a>
  97. <?php
  98. }
  99. }
  100. ?>
  101. </div>
  102. </div>
  103. <div class="columns">
  104. <div class="column is-one-third">
  105. <p><?php echo $T->t('view.categories'); ?></p>
  106. </div>
  107. <div class="column is-two-third">
  108. <?php
  109. if(!empty($linkData['categories'])) {
  110. foreach($linkData['categories'] as $k=>$v) {
  111. ?>
  112. <a href="index.php?p=overview&m=category&id=<?php echo urlencode($k); ?>" class="button is-small">
  113. <span class="icon"><i class="ion-md-filing"></i></span>
  114. <span><?php echo $v; ?></span>
  115. </a>
  116. <?php
  117. }
  118. }
  119. ?>
  120. </div>
  121. </div>
  122. <?php if($_displayEditButton === true) { ?>
  123. <div class="columns">
  124. <div class="column">
  125. <a href="index.php?p=editlink&id=<?php echo $linkData['hash']; ?>" class="button is-small is-danger">
  126. <span class="icon">
  127. <i class="ion-md-create"></i>
  128. </span>
  129. <span><?php echo $T->t('view.edit'); ?></span>
  130. </a>
  131. <a href="index.php?p=editlink&id=<?php echo $linkData['hash']; ?>&m=export" class="button is-small is-success">
  132. <span class="icon">
  133. <i class="ion-md-download"></i>
  134. </span>
  135. <span><?php echo $T->t('view.export'); ?></span>
  136. </a>
  137. </div>
  138. </div>
  139. <?php } ?>
  140. </section>