Changeset 1601082
- Timestamp:
- 02/22/2017 06:31:49 AM (9 years ago)
- Location:
- cf7-ui-slider/trunk
- Files:
-
- 3 edited
-
cf7-ui-slider.php (modified) (2 diffs)
-
includes/slider-tag.php (modified) (1 diff)
-
readme.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
cf7-ui-slider/trunk/cf7-ui-slider.php
r1575498 r1601082 4 4 * Plugin URI: http://ayushmalakar.com.np/ 5 5 * Description: A simple way to add jQuery UI Slider to your contact form 7 6 * Version: 1.5. 06 * Version: 1.5.1 7 7 * Author: Ayush Malakar 8 8 * Author URI: http://ayushmalakar.com.np/ … … 21 21 * @var string 22 22 */ 23 const VERSION = '1.5. 0';23 const VERSION = '1.5.1'; 24 24 25 25 /** -
cf7-ui-slider/trunk/includes/slider-tag.php
r1575498 r1601082 47 47 48 48 ob_start(); 49 $default_value = ! empty( $atts[ 'ui_default' ] ) ? $atts[ 'ui_default' ]: $atts[ 'min' ];49 $default_value = ! empty( $atts[ 'ui_default' ] ) ? $atts[ 'ui_default' ] : $atts[ 'min' ]; 50 50 ?> 51 <script>52 jQuery(function ($) {53 $("#<?php echo $atts[ 'connect' ] ?>").css('display', 'none');54 var tooltip = $('<div class="slider-tooltip" />').css({55 position: 'absolute'56 });57 58 tooltip.text(<?php echo $default_value ?>);59 60 $("#<?php echo $atts[ 'id' ]; ?>").slider({61 range: "min",62 min: <?php echo $atts[ 'min' ]; ?>,63 max: <?php echo $atts[ 'max' ];?>,64 value: <?php echo $default_value ?>,65 slide: function (event, ui) {66 $("#<?php echo $atts[ 'connect' ] ?>").val(ui.value);67 tooltip.text(ui.value);68 },69 change: function (event, ui) {70 }71 }).find(".ui-slider-handle").append(tooltip);72 $("#<?php echo $atts[ 'connect' ] ?>").val($("#<?php $atts[ 'connect' ]?>").slider("value"));73 });74 </script>75 51 76 52 77 53 <div id="<?php echo $atts[ 'id' ]; ?>"></div> 54 <script> 55 jQuery(function ($) { 56 $(window).ready(function () { 57 $("#<?php echo $atts[ 'connect' ] ?>").css('display', 'none'); 58 var tooltip = $('<div class="slider-tooltip" />').css({ 59 position: 'absolute' 60 }); 61 62 tooltip.text(<?php echo $default_value ?>); 63 64 $("#<?php echo $atts[ 'id' ]; ?>").slider({ 65 range: "min", 66 min: <?php echo $atts[ 'min' ]; ?>, 67 max: <?php echo $atts[ 'max' ];?>, 68 value: <?php echo $default_value ?>, 69 slide: function (event, ui) { 70 $("#<?php echo $atts[ 'connect' ] ?>").val(ui.value); 71 tooltip.text(ui.value); 72 }, 73 change: function (event, ui) { 74 } 75 }).find(".ui-slider-handle").append(tooltip); 76 $("#<?php echo $atts[ 'connect' ] ?>").val(<?php echo $default_value ?>); 77 }); 78 }); 79 </script> 78 80 <?php 79 81 return ob_get_clean(); -
cf7-ui-slider/trunk/readme.txt
r1575527 r1601082 35 35 N/A 36 36 37 == Screenshot s==37 == Screenshot == 38 38 1. Admin section panel 39 39 2. Fields for the slider … … 41 41 42 42 == Changelog == 43 44 = 1.0.0 = 45 * Initial Release 43 ==1.5.1== 44 Bug fixed: Default Value not being passed. Default value will now be sent to email if user does not slider the slider 46 45 = 1.5.0 = 47 46 * Added touch support for mobile devices … … 49 48 * Now supports default value 50 49 * Auto Hide connector field 50 = 1.0.0 = 51 * Initial Release 51 52 52 53 53 54 54 55 56 57
Note: See TracChangeset
for help on using the changeset viewer.