Nextgen template changed to have links
authorLaury GvR <laury@gaslightmedia.com>
Fri, 3 Jun 2016 17:35:57 +0000 (13:35 -0400)
committerLaury GvR <laury@gaslightmedia.com>
Fri, 3 Jun 2016 17:35:57 +0000 (13:35 -0400)
nggallery/gallery-glmphotos-linked.php [new file with mode: 0644]
style.css

diff --git a/nggallery/gallery-glmphotos-linked.php b/nggallery/gallery-glmphotos-linked.php
new file mode 100644 (file)
index 0000000..6948137
--- /dev/null
@@ -0,0 +1,106 @@
+<?php 
+/**
+Template Page for the gallery overview
+
+Follow variables are useable :
+
+       $gallery     : Contain all about the gallery
+       $images      : Contain all images, path, title
+       $pagination  : Contain the pagination content
+
+ You can check the content when you insert the tag <?php var_dump($variable) ?>
+ If you would like to show the timestamp of the image ,you can use <?php echo $exif['created_timestamp'] ?>
+**/
+?>
+<?php if (!defined ('ABSPATH')) die ('No direct access allowed'); ?><?php if (!empty ($gallery)) : ?>
+
+       <!-- Thumbnails -->
+    <?php $i = 0; ?>
+        <ul class="gallery row small-block-grid-2 medium-block-grid-3 large-block-grid-4">
+       <?php foreach ( $images as $image ) : ?>
+        <li>
+            <div id="ngg-image-<?php echo $image->pid ?>" class="ngg-gallery-thumbnail-box imgBorderMe" <?php echo $image->style ?> >
+                    <?php if (filter_var(esc_attr($image->description), FILTER_VALIDATE_URL) === FALSE) {
+                       $innerdescription = "This Website is under construction - check back soon!";
+                       $validlink = false;
+                    } else {
+                       $innerdescription = $image->description;
+                       $validlink = true;
+                    } ?>
+                <div class="ngg-gallery-thumbnail" >
+                    <a href="<?php echo nextgen_esc_url($image->imageURL) ?>"
+                       <?php if ($validlink) { ?>
+                       title="Visit the <a href='<?php echo $innerdescription ?>' target='_blank'> <?php echo esc_attr($image->alttext) ?></a> Website"
+                       <?php } else { ?>
+                       title="<?php echo $innerdescription ?>"
+                       <?php } ?>
+                
+                        data-src="<?php echo nextgen_esc_url($image->imageURL) ?>"
+                        data-thumbnail="<?php echo nextgen_esc_url($image->thumbnailURL); ?>"
+                        data-image-id="<?php echo esc_attr($image->pid); ?>"
+                        data-title="<?php echo esc_attr($image->alttext); ?>"
+                        data-description="<?php echo $innerdescription; ?>"
+                <?php echo $image->thumbcode ?> >
+                    <?php if ( !$image->hidden ) { ?>
+
+                        <img
+                        title="<?php echo esc_attr($image->alttext) ?>"
+                        alt="<?php echo esc_attr($image->alttext) ?>"
+                        src="<?php echo nextgen_esc_url($image->thumbnailURL) ?>"
+                        <?php echo $image->size ?> />
+
+                        <?php } ?>
+                        <div class="image_title">
+                            <h5 class="title">
+                                VIEW
+                            </h5>
+                        </div>
+                    </a>
+                    <?php
+                    $imageTitle = !preg_match(';is\d{2,}-\d{10,}-\d{5,}$;', $image->alttext) ? $image->alttext: '';
+                    ?>
+                        <?php if ($validlink) { ?>
+                   <div class="photoTitle"> 
+                            <a href="<?php echo $innerdescription ?>"  target="_blank">
+                                <div title="Visit the <?php echo esc_attr($image->alttext) ?> website!"
+                                    alt="<?php echo esc_attr($image->alttext) ?>">
+                                    <?php if (!$image->hidden) { echo esc_attr($imageTitle); }?>
+                                </div>
+                            </a>
+                        <?php } else { ?>
+                   <div class="photoTitle"> 
+                        <a href="<?php echo nextgen_esc_url($image->imageURL) ?>"
+                            <?php if ($validlink) { ?>
+                            title="Visit the <a href='<?php echo $innerdescription ?>' target='_blank'> <?php echo esc_attr($image->alttext) ?></a> Website"
+                            <?php } else { ?>
+                            title="<?php echo $innerdescription ?>"
+                            <?php } ?>
+
+                             data-src="<?php echo nextgen_esc_url($image->imageURL) ?>"
+                             data-thumbnail="<?php echo nextgen_esc_url($image->thumbnailURL); ?>"
+                             data-image-id="<?php echo esc_attr($image->pid); ?>"
+                             data-title="<?php echo esc_attr($image->alttext); ?>"
+                             data-description="<?php echo $innerdescription; ?>"
+                            <?php echo $image->thumbcode ?> >
+                            <div title="<?php echo $innerdescription ?>"
+                                alt="<?php echo $innerdescription ?>">
+                                <?php if (!$image->hidden) { echo esc_attr($imageTitle); }?>
+                            </div>
+                       </a>
+                       <?php } ?>
+                    </div>
+                </div>
+
+            </div>
+        </li>
+       <?php if ( $image->hidden ) continue; ?>
+       <?php if ( $gallery->columns > 0 && ++$i % $gallery->columns == 0 ) { ?>
+       <br style="clear: both" />
+       <?php } ?>
+       <?php endforeach; ?>
+        </ul>
+       <!-- Pagination -->
+       <?php echo $pagination ?>
+</ul>
+
+<?php endif; ?>
index 2900ce9..cabaa67 100644 (file)
--- a/style.css
+++ b/style.css
@@ -1,7 +1,7 @@
 /*
-Theme Name: EmmetCountyFair
+Theme Name: Gaylord Alpenfest
 Author: Gaslight Media
 Author URI: http://www.gaslightmedia.com
-Description: A theme for EmmetCountyFair
+Description: A theme for Gaylord Alpenfest
 Version: 2.0.10
 */