Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Removed display desc under thumbnail feature

  • Loading branch information...
commit fca4a673e0c2a40465de0c836d99781e08b494a6 1 parent fb24567
@jeroenrnl authored
View
3  php/config.inc.php
@@ -232,7 +232,8 @@
// the maximum number of characters of a description to display
// under a thumbnail (see also desc_thumbnail pref). Set this
// to 0 to disable this feature (and override a user's pref).
- define('MAX_THUMB_DESC', 40);
+ // Deprecated
+ //define('MAX_THUMB_DESC', 40);
define('THUMB_SIZE', 120);
define('MID_SIZE', 480);
View
4 php/photo_search.inc.php
@@ -29,10 +29,6 @@ function get_photos($vars, $offset, $rows, &$thumbnails, $user = null) {
if(!is_numeric($offset)) { die("offset must be numeric"); }
if(!is_numeric($rows)) { die("rows must be numeric"); }
- if (MAX_THUMB_DESC && $user && $user->prefs->get("desc_thumbnails")) {
- $select .= ", ph.description";
- }
-
$from_clause=DB_PREFIX . "photos as ph";
if ($user && !$user->is_admin()) {
View
12 php/photos.php
@@ -153,10 +153,6 @@
</form>
<br>
<?php
- if (MAX_THUMB_DESC && $user->prefs->get("desc_thumbnails")) {
- $desc_thumbnails = true;
- }
-
for ($i = 0; $i < $num; $i++) {
if ($i > 0 && $i % $_cols == 0) {
@@ -173,16 +169,8 @@
} else {
echo $thumbnails[$i]->get_thumbnail_link("photo.php?" . update_query_string($vars, "_off", $offset + $i, $ignore)) . "\n";
}
- if (!empty($desc_thumbnails) && $thumbnails[$i]->get("description")) {
-?>
- <br>
- <div class="thumbdesc"><?php echo substr($thumbnails[$i]->get("description"), 0, MAX_THUMB_DESC) ?></div>
-<?php
- if (strlen($thumbnails[$i]->get("description")) > MAX_THUMB_DESC) { echo "..."; }
- }
if (!empty($lightbox)) {
- if (!isset($desc_thumbnails)) { echo "<br>\n"; }
?>
<div class="actionlink"><a href="photos.php?<?php echo update_query_string($vars, "_photo_id", $thumbnails[$i]->get("photo_id"), $ignore) ?>">x</a></div>
<?php
View
12 php/prefs.php
@@ -112,18 +112,6 @@
<dd>
<?php echo create_text_input("recent_photo_days", $user->prefs->get("recent_photo_days"), 4, 4) ?>
</dd>
-<?php
- if (MAX_THUMB_DESC) {
-?>
- <dt>
- <?php echo translate("show descriptions under thumbnails") ?>
- </dt>
- <dd>
- <?php echo create_pulldown("desc_thumbnails", $user->prefs->get("desc_thumbnails"), array("1" => translate("Yes",0), "0" => translate("No",0)) ) ?>
- </dd>
-<?php
- }
-?>
<dt>
<?php echo translate("open fullsize photo in new window") ?>
</dt>
View
2  sql/zoph_update-0.10.sql
@@ -31,3 +31,5 @@ CREATE TABLE zoph_conf (
timestamp timestamp,
PRIMARY kEY (conf_id)
) EGINE=MyISAM;
+
+ALTER TABLE zoph_prefs DROP COLUMN desc_thumbnails;
Please sign in to comment.
Something went wrong with that request. Please try again.