Changeset 670289
- Timestamp:
- 02/19/2013 01:47:23 PM (13 years ago)
- Location:
- nextgen-flex-slider-template
- Files:
-
- 21 added
- 5 edited
-
assets/screenshot-3.png (modified) (previous)
-
tags/1.7 (added)
-
tags/1.7/admin-settings.php (added)
-
tags/1.7/css (added)
-
tags/1.7/css/black.css (added)
-
tags/1.7/css/blue.css (added)
-
tags/1.7/css/flexslider-default.css (added)
-
tags/1.7/css/grey.css (added)
-
tags/1.7/css/style.css (added)
-
tags/1.7/images (added)
-
tags/1.7/images/black (added)
-
tags/1.7/images/black/bg_direction_nav.png (added)
-
tags/1.7/images/blue (added)
-
tags/1.7/images/blue/flex-slide-nav.png (added)
-
tags/1.7/images/blue/prev-next.png (added)
-
tags/1.7/images/grey (added)
-
tags/1.7/images/grey/bg_direction_nav.png (added)
-
tags/1.7/js (added)
-
tags/1.7/js/jquery.flexslider-min.js (added)
-
tags/1.7/nextgen-flex-slider-template.php (added)
-
tags/1.7/readme.txt (added)
-
tags/1.7/template-nggsliderview.php (added)
-
trunk/admin-settings.php (modified) (5 diffs)
-
trunk/nextgen-flex-slider-template.php (modified) (1 diff)
-
trunk/readme.txt (modified) (7 diffs)
-
trunk/template-nggsliderview.php (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
nextgen-flex-slider-template/trunk/admin-settings.php
r666267 r670289 17 17 register_setting('ng_slider_options', 'ng_slider_display_content'); 18 18 register_setting('ng_slider_options', 'ng_slider_image_width'); 19 //register_setting('ng_slider_options', 'ng_slider_image_height'); 19 20 register_setting('ng_slider_options', 'ng_slider_text_width'); 20 21 register_setting('ng_slider_options', 'ng_slider_slideshow_speed'); … … 24 25 //register_setting('ng_slider_options', 'ng_slider_direction'); 25 26 //register_setting('ng_slider_options', 'ng_slider_animation'); 27 register_setting('ng_slider_options', 'ng_slider_link_title'); 28 register_setting('ng_slider_options', 'ng_slider_link_image'); 29 register_setting('ng_slider_options', 'ng_slider_link_new_window'); 26 30 register_setting('ng_slider_options', 'ng_slider_direction_nav'); 27 31 register_setting('ng_slider_options', 'ng_slider_pagination'); … … 35 39 add_settings_field('ng_slider_disable_img_stretching', '', 'ng_slider_disable_img_stretching', 'ng_slider_general_options', 'ng_slider_general_options'); 36 40 add_settings_field('ng_slider_text_width', 'Content Width', 'ng_slider_text_width_code', 'ng_slider_general_options', 'ng_slider_general_options'); 41 //add_settings_field('ng_slider_image_height', 'Limit Image Height', 'ng_slider_image_height', 'ng_slider_general_options', 'ng_slider_general_options'); 42 add_settings_field('ng_slider_link_title', 'Linking Sliders', 'ng_slider_link_title', 'ng_slider_general_options', 'ng_slider_general_options'); 43 add_settings_field('ng_slider_link_image', '', 'ng_slider_link_image', 'ng_slider_general_options', 'ng_slider_general_options'); 44 add_settings_field('ng_slider_link_new_window', '', 'ng_slider_link_new_window', 'ng_slider_general_options', 'ng_slider_general_options'); 37 45 add_settings_field('ng_slider_background', 'Background Color', 'ng_slider_background', 'ng_slider_general_options', 'ng_slider_general_options'); 38 46 add_settings_field('ng_slider_slideshow_speed', 'Animation Delay', 'ng_slider_slideshow_speed_code', 'ng_slider_general_options', 'ng_slider_general_options'); … … 53 61 function ng_slider_disable_img_stretching() { 54 62 echo '<label><input id="ng_slider_disable_img_stretching" name="ng_slider_disable_img_stretching" type="checkbox" value="1" ' . checked(get_option("ng_slider_disable_img_stretching"), '1', false ) . ' /> Disable image stretching. If images are pixelated pease check this option.</label>'; 63 } 64 function ng_slider_link_title() { 65 echo 'Follow <a href="http://wpdevsnippets/linking-image-and-title-nextgen-flex-slider-template" target="_blank">this tutorial</a> to set it up.<br /><label><input id="ng_slider_link_title" name="ng_slider_link_title" type="checkbox" value="1" ' . checked(get_option("ng_slider_link_title"), '1', false ) . ' /> Link title to specified URL. </label>'; 66 } 67 function ng_slider_link_image() { 68 echo '<label><input id="ng_slider_link_image" name="ng_slider_link_image" type="checkbox" value="1" ' . checked(get_option("ng_slider_link_image"), '1', false ) . ' /> Link image to specified URL. </label>'; 69 } 70 function ng_slider_link_new_window() { 71 echo '<label><input id="ng_slider_link_new_window" name="ng_slider_link_new_window" type="checkbox" value="1" ' . checked(get_option("ng_slider_link_new_window"), '1', false ) . ' /> Open links in a new window</label>'; 72 } 73 74 75 function ng_slider_image_height() { 76 echo '<input id="ng_slider_image_height" name="ng_slider_image_height" type="text" value="' . get_option("ng_slider_image_height") . '" /> e.g. any valid height value. 300px etc<br />'; 55 77 } 56 78 … … 166 188 <em>Possible Values</em>: 100px or 20% etc</p> 167 189 190 <p><strong>link_title:</strong> <br> 191 (boolean) (optional) Enable or disable whether title should be linked or not (for content slider). Please follow <a href="http://wpdevsnippets/linking-image-and-title-nextgen-flex-slider-template" target="_blank">this tutorial</a> to set it up<br> 192 <em>Possible Values</em>: 0 or 1</p> 193 194 <p><strong>link_image:</strong> <br> 195 (boolean) (optional) Enable or disable whether image should be linked or not. Please follow <a href="http://wpdevsnippets/linking-image-and-title-nextgen-flex-slider-template" target="_blank">this tutorial</a> to set it up<br> 196 <em>Possible Values</em>: 0 or 1</p> 197 198 <p><strong>link_new_window:</strong> <br> 199 (boolean) (optional) Enable to open slider url to be opened in a new window. Please follow <a href="http://wpdevsnippets/linking-image-and-title-nextgen-flex-slider-template" target="_blank">this tutorial</a> to set it up<br> 200 <em>Possible Values</em>: 0 or 1</p> 201 168 202 <p><strong>background:</strong> <br> 169 203 (string) (optional) Set background color of the slider <br> -
nextgen-flex-slider-template/trunk/nextgen-flex-slider-template.php
r666267 r670289 6 6 Author: Mohsin Rasool 7 7 Author URI: http://wpdevsnippets.com 8 Version: 1. 68 Version: 1.7 9 9 */ 10 10 -
nextgen-flex-slider-template/trunk/readme.txt
r666267 r670289 5 5 Requires at least: 3.0.1 6 6 Tested up to: 3.5 7 Stable tag: 1. 67 Stable tag: 1.7 8 8 Author: Mohsin Rasool 9 9 License: GPLv2 … … 42 42 direction_nav: 43 43 (boolean) (optional) Enable or disable next/prev navigation arrows 44 Possible Values: 1 or 044 Possible Values: 0 or 1 45 45 46 46 pagination: 47 47 (boolean) (optional) Enable or disable pagination bullets at bottom 48 Possible Values: 1 or 048 Possible Values: 0 or 1 49 49 50 50 image_width: … … 55 55 (string) (optional) Set width of the content area (in case of content slider) 56 56 Possible Values: 100px or 20% etc 57 58 link_title: 59 (boolean) (optional) Enable or disable whether title should be linked or not (for content slider). Please follow [this tutorial](http://wpdevsnippets/linking-image-and-title-nextgen-flex-slider-template "Linking Flex Sliders") to set it up 60 Possible Values: 0 or 1 61 62 link_image: 63 (boolean) (optional) Enable or disable whether image should be linked or not. Please follow [this tutorial](http://wpdevsnippets/linking-image-and-title-nextgen-flex-slider-template "Linking Flex Sliders") to set it up 64 Possible Values: 0 or 1 65 66 link_new_window: 67 (boolean) (optional) Enable to open slider url to be opened in a new window. Please follow [this tutorial](http://wpdevsnippets/linking-image-and-title-nextgen-flex-slider-template "Linking Flex Sliders") to set it up 68 Possible Values: 0 or 1 57 69 58 70 background: … … 70 82 == Usage == 71 83 72 [nggallery id=x template="sliderview" ]84 [nggallery id=x template="sliderview" direction_nav="0"] 73 85 74 86 == Installation == … … 123 135 == Changelog == 124 136 137 = 1.7 = 138 * Added feature to link the images and titles 139 * Fixed open_short_tag bug 140 125 141 = 1.6 = 126 142 * Allow multiple slider with different options on the same page or different pages … … 156 172 == Upgrade Notice == 157 173 174 = 1.7 = 175 * Added feature to link the images and titles 176 * Fixed open_short_tag bug 177 158 178 = 1.6 = 159 179 * Allow multiple slider with different options on the same page or different pages … … 172 192 173 193 = 1.2 = 174 Fixes blank screen bug when activated. It may also conflict with another plugin.194 * Fixes blank screen bug when activated. It may also conflict with another plugin. -
nextgen-flex-slider-template/trunk/template-nggsliderview.php
r666267 r670289 15 15 ?> 16 16 <?php if (!defined ('ABSPATH')) die ('No direct access allowed'); ?><?php if (!empty ($gallery)) : ?> 17 <? 17 <?php 18 18 19 // Parse the attributes 19 20 $defaults = array ( … … 28 29 'ng_slider_text_width' => get_option('ng_slider_text_width'), 29 30 'ng_slider_use_width_for_img_slider' => get_option('ng_slider_use_width_for_img_slider'), 30 'ng_slider_disable_img_stretching' => get_option('ng_slider_disable_img_stretching') 31 'ng_slider_disable_img_stretching' => get_option('ng_slider_disable_img_stretching'), 32 'ng_slider_link_title' => get_option('ng_slider_link_title'), 33 'ng_slider_link_image' => get_option('ng_slider_link_image'), 34 'ng_slider_link_new_window' => get_option('ng_slider_link_new_window') 31 35 ); 32 36 37 33 38 $ng_slider_theme_names = array('black','blue','grey'); 34 39 … … 62 67 } 63 68 } 69 64 70 extract($defaults); 65 71 … … 71 77 $images = array_reverse($images); 72 78 ?> 73 <div id="<?php echo $gallery->anchor ?>" class="flexslider <? =$ng_slider_theme?>">79 <div id="<?php echo $gallery->anchor ?>" class="flexslider <?php echo $ng_slider_theme?>"> 74 80 <ul class="slides"> 75 81 <!-- Thumbnails --> 76 <?php foreach ($images as $image) : ?> 77 <li class="<? if(!$display_content) echo 'full-width';?>">82 <?php foreach ($images as $image) : ?> 83 <li class="<?php if(!$display_content) echo 'full-width';?>"> 78 84 <div class="feature-image "> 79 <img class="full home_feature" src="<?php echo $image->imageURL ?>" alt="<?php echo $image->alttext ?>" title="<?php echo $image->alttext ?>"> 85 <?php if(!empty($image->ngg_custom_fields['image_link']) && $ng_slider_link_image) { ?> 86 <a href="<?php echo $image->ngg_custom_fields['image_link'] ?>" <?php echo $ng_slider_link_new_window ? 'target="_blank"':'' ?> ><img class="full home_feature" src="<?php echo $image->imageURL ?>" alt="<?php echo $image->alttext ?>" title="<?php echo $image->alttext ?>"></a> 87 <?php }else{ ?> 88 <img class="full home_feature" src="<?php echo $image->imageURL ?>" alt="<?php echo $image->alttext ?>" title="<?php echo $image->alttext ?>"> 89 <?php } ?> 90 80 91 </div> 81 <? if($display_content) {?>92 <?php if($display_content) {?> 82 93 <div class="flex-caption"> 83 <h2 class="post-title"><?php echo ($image->alttext) ?></h2> 94 <?php if(!empty($image->ngg_custom_fields['image_link']) && $ng_slider_link_title) { ?> 95 <a href="<?php echo $image->ngg_custom_fields['image_link'] ?>" <?php echo $ng_slider_link_new_window ? 'target="_blank"':'' ?> ><h2 class="post-title"><?php echo ($image->alttext) ?></h2></a> 96 <?php }else{ ?> 97 <h2 class="post-title"><?php echo ($image->alttext) ?></h2> 98 <?php } ?> 84 99 <p><?php echo html_entity_decode($image->description) ?></p> 85 100 </div> 86 <? } ?>101 <?php } ?> 87 102 </li> 88 103 <?php endforeach; ?> … … 94 109 jQuery(document).ready(function($) { 95 110 $('#<?php echo $gallery->anchor ?>').flexslider({ 96 <? echo "slideshowSpeed: ".($ng_slider_slideshow_speed ? $ng_slider_slideshow_speed*1000: 6000).","?>97 <? //echo "direction: '".(get_option('ng_slider_direction') ? get_option('ng_slider_direction'): 'horizontal')."',"?>98 <? if($ng_slider_order == 'random')111 <?php echo "slideshowSpeed: ".($ng_slider_slideshow_speed ? $ng_slider_slideshow_speed*1000: 6000).","?> 112 <?php //echo "direction: '".(get_option('ng_slider_direction') ? get_option('ng_slider_direction'): 'horizontal')."',"?> 113 <?php if($ng_slider_order == 'random') 99 114 echo 'randomize:true,'; 100 115 101 116 ?> 102 <? echo "directionNav: ".($ng_slider_direction_nav ? 'true': 'false').","?>103 <? echo "controlNav: ".($ng_slider_pagination ? 'true': 'false').","?>104 <? //echo "animation: '".(get_option('ng_slider_animation') ? get_option('ng_slider_animation'): 'fade')."',"?>117 <?php echo "directionNav: ".($ng_slider_direction_nav ? 'true': 'false').","?> 118 <?php echo "controlNav: ".($ng_slider_pagination ? 'true': 'false').","?> 119 <?php //echo "animation: '".(get_option('ng_slider_animation') ? get_option('ng_slider_animation'): 'fade')."',"?> 105 120 pauseOnHover:true 106 121 }); … … 108 123 </script> 109 124 <style> 110 <? 125 <?php 111 126 $img_width = $ng_slider_image_width; 112 127 $bg_color = $ng_slider_background;
Note: See TracChangeset
for help on using the changeset viewer.