Version Description
- Improved settings page design
- Added shortcode nivo_slider
- Added shortcode photoshop
Download this release
Release Info
Developer | gn_themes |
Plugin | Shortcodes Ultimate |
Version | 1.7.0 |
Comparing to | |
See all releases |
Code changes from version 1.6.1 to 1.7.0
- css/admin.css +27 -25
- css/nivo-slider.css +89 -0
- css/style.css +63 -0
- images/admin/tab.png +0 -0
- images/admin/tabs.png +0 -0
- images/nivo-slider/arrows.png +0 -0
- images/nivo-slider/bullets.png +0 -0
- images/nivo-slider/loading.gif +0 -0
- js/admin.js +2 -2
- js/jquery.nivo.slider.pack.js +67 -0
- languages/shortcodes-ultimate-ru_RU.mo +0 -0
- languages/shortcodes-ultimate-ru_RU.po +20 -7
- lib/admin.php +19 -9
- lib/shortcodes.php +101 -0
- readme.txt +14 -2
- shortcodes-ultimate.php +7 -1
css/admin.css
CHANGED
@@ -28,46 +28,48 @@
|
|
28 |
|
29 |
/* Tabs */
|
30 |
#su-tabs {
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
padding: 5px 5px 0 5px;
|
35 |
-
border-right: 1px solid #333;
|
36 |
-
border-top: 1px solid #333;
|
37 |
-
border-left: 1px solid #333;
|
38 |
-
background: #333;
|
39 |
}
|
40 |
-
#su-tabs
|
41 |
display: block;
|
42 |
float: left;
|
43 |
-
height:
|
44 |
-
|
|
|
45 |
cursor: pointer;
|
|
|
|
|
|
|
|
|
|
|
46 |
}
|
47 |
#su-tabs span {
|
48 |
display: block;
|
49 |
-
height:
|
50 |
-
line-height:
|
51 |
-
padding: 0
|
52 |
-
|
53 |
-
}
|
54 |
-
#su-tabs li:hover span {
|
55 |
-
background: #f0f0f0;
|
56 |
color: #333;
|
57 |
}
|
58 |
-
#su-tabs
|
|
|
|
|
|
|
|
|
59 |
#su-tabs .su-current span {
|
60 |
-
|
61 |
-
|
62 |
}
|
63 |
|
64 |
.su-pane {
|
65 |
display: none;
|
66 |
-
width:
|
67 |
background: #fff;
|
68 |
padding: 15px;
|
69 |
margin-bottom: 30px;
|
70 |
-
border-right: 1px solid #
|
71 |
-
border-bottom: 1px solid #
|
72 |
-
border-left: 1px solid #
|
73 |
}
|
28 |
|
29 |
/* Tabs */
|
30 |
#su-tabs {
|
31 |
+
width: 700px;
|
32 |
+
height: 33px;
|
33 |
+
background: url(../images/admin/tabs.png) no-repeat;
|
|
|
|
|
|
|
|
|
|
|
34 |
}
|
35 |
+
#su-tabs a {
|
36 |
display: block;
|
37 |
float: left;
|
38 |
+
height: 33px;
|
39 |
+
padding: 0 0 0 10px;
|
40 |
+
margin: 0 0 0 5px;
|
41 |
cursor: pointer;
|
42 |
+
color: #333;
|
43 |
+
font-weight: bold;
|
44 |
+
font-size: 12px;
|
45 |
+
text-decoration: none;
|
46 |
+
text-shadow: 0 1px 0 #fff;
|
47 |
}
|
48 |
#su-tabs span {
|
49 |
display: block;
|
50 |
+
height: 33px;
|
51 |
+
line-height: 39px;
|
52 |
+
padding: 0 10px 0 0;
|
53 |
+
text-decoration: none;
|
|
|
|
|
|
|
54 |
color: #333;
|
55 |
}
|
56 |
+
#su-tabs a:hover,
|
57 |
+
#su-tabs .su-current {
|
58 |
+
background: url(../images/admin/tab.png) no-repeat;
|
59 |
+
}
|
60 |
+
#su-tabs a:hover span,
|
61 |
#su-tabs .su-current span {
|
62 |
+
line-height: 34px;
|
63 |
+
background: 100% 100% url(../images/admin/tab.png) no-repeat;
|
64 |
}
|
65 |
|
66 |
.su-pane {
|
67 |
display: none;
|
68 |
+
width: 668px;
|
69 |
background: #fff;
|
70 |
padding: 15px;
|
71 |
margin-bottom: 30px;
|
72 |
+
border-right: 1px solid #DFDFDF;
|
73 |
+
border-bottom: 1px solid #DFDFDF;
|
74 |
+
border-left: 1px solid #DFDFDF;
|
75 |
}
|
css/nivo-slider.css
ADDED
@@ -0,0 +1,89 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*
|
2 |
+
* jQuery Nivo Slider v2.5.1
|
3 |
+
* http://nivo.dev7studios.com
|
4 |
+
*
|
5 |
+
* Copyright 2011, Gilbert Pellegrom
|
6 |
+
* Free to use and abuse under the MIT license.
|
7 |
+
* http://www.opensource.org/licenses/mit-license.php
|
8 |
+
*
|
9 |
+
* March 2010
|
10 |
+
*/
|
11 |
+
|
12 |
+
|
13 |
+
/* The Nivo Slider styles */
|
14 |
+
.nivoSlider {
|
15 |
+
position:relative;
|
16 |
+
}
|
17 |
+
.nivoSlider img {
|
18 |
+
position:absolute;
|
19 |
+
top:0px;
|
20 |
+
left:0px;
|
21 |
+
}
|
22 |
+
/* If an image is wrapped in a link */
|
23 |
+
.nivoSlider a.nivo-imageLink {
|
24 |
+
position:absolute;
|
25 |
+
top:0px;
|
26 |
+
left:0px;
|
27 |
+
width:100%;
|
28 |
+
height:100%;
|
29 |
+
border:0;
|
30 |
+
padding:0;
|
31 |
+
margin:0;
|
32 |
+
z-index:6;
|
33 |
+
display:none;
|
34 |
+
}
|
35 |
+
/* The slices and boxes in the Slider */
|
36 |
+
.nivo-slice {
|
37 |
+
display:block;
|
38 |
+
position:absolute;
|
39 |
+
z-index:5;
|
40 |
+
height:100%;
|
41 |
+
}
|
42 |
+
.nivo-box {
|
43 |
+
display:block;
|
44 |
+
position:absolute;
|
45 |
+
z-index:5;
|
46 |
+
}
|
47 |
+
/* Caption styles */
|
48 |
+
.nivo-caption {
|
49 |
+
position:absolute;
|
50 |
+
left:0px;
|
51 |
+
bottom:0px;
|
52 |
+
background:#000;
|
53 |
+
color:#fff;
|
54 |
+
opacity:0.8; /* Overridden by captionOpacity setting */
|
55 |
+
width:100%;
|
56 |
+
z-index:8;
|
57 |
+
}
|
58 |
+
.nivo-caption p {
|
59 |
+
padding:5px;
|
60 |
+
margin:0;
|
61 |
+
}
|
62 |
+
.nivo-caption a {
|
63 |
+
display:inline !important;
|
64 |
+
}
|
65 |
+
.nivo-html-caption {
|
66 |
+
display:none;
|
67 |
+
}
|
68 |
+
/* Direction nav styles (e.g. Next & Prev) */
|
69 |
+
.nivo-directionNav a {
|
70 |
+
position:absolute;
|
71 |
+
top:45%;
|
72 |
+
z-index:9;
|
73 |
+
cursor:pointer;
|
74 |
+
}
|
75 |
+
.nivo-prevNav {
|
76 |
+
left:0px;
|
77 |
+
}
|
78 |
+
.nivo-nextNav {
|
79 |
+
right:0px;
|
80 |
+
}
|
81 |
+
/* Control nav styles (e.g. 1,2,3...) */
|
82 |
+
.nivo-controlNav a {
|
83 |
+
position:relative;
|
84 |
+
z-index:9;
|
85 |
+
cursor:pointer;
|
86 |
+
}
|
87 |
+
.nivo-controlNav a.active {
|
88 |
+
font-weight:bold;
|
89 |
+
}
|
css/style.css
CHANGED
@@ -93,6 +93,7 @@
|
|
93 |
}
|
94 |
.su-frame img {
|
95 |
display: block !important;
|
|
|
96 |
padding: 0 !important;
|
97 |
margin: 0 !important;
|
98 |
}
|
@@ -417,4 +418,66 @@
|
|
417 |
}
|
418 |
.su-table-style-3 .su-even td {
|
419 |
background: #fff !important;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
420 |
}
|
93 |
}
|
94 |
.su-frame img {
|
95 |
display: block !important;
|
96 |
+
float: none !important;
|
97 |
padding: 0 !important;
|
98 |
margin: 0 !important;
|
99 |
}
|
418 |
}
|
419 |
.su-table-style-3 .su-even td {
|
420 |
background: #fff !important;
|
421 |
+
}
|
422 |
+
|
423 |
+
/* Nivo slider */
|
424 |
+
#su-nivo-slider {
|
425 |
+
position: relative;
|
426 |
+
margin: 0 0 1.5em 0;
|
427 |
+
background: #f8f8f8 url(../images/nivo-slider/loading.gif) no-repeat 50% 50%;
|
428 |
+
}
|
429 |
+
#su-nivo-slider img {
|
430 |
+
position: absolute;
|
431 |
+
top: 0;
|
432 |
+
left: 0;
|
433 |
+
display: none;
|
434 |
+
}
|
435 |
+
#su-nivo-slider a {
|
436 |
+
border: 0;
|
437 |
+
display: block;
|
438 |
+
}
|
439 |
+
|
440 |
+
.nivo-controlNav {
|
441 |
+
position: absolute;
|
442 |
+
right: 10px;
|
443 |
+
bottom: 10px;
|
444 |
+
}
|
445 |
+
.nivo-controlNav a {
|
446 |
+
display: block;
|
447 |
+
width: 22px;
|
448 |
+
height: 22px;
|
449 |
+
background: url(../images/nivo-slider/bullets.png) no-repeat;
|
450 |
+
text-indent: -9999px;
|
451 |
+
border: 0;
|
452 |
+
margin-right: 3px;
|
453 |
+
float: left;
|
454 |
+
}
|
455 |
+
.nivo-controlNav a:hover,
|
456 |
+
.nivo-controlNav a.active {
|
457 |
+
background-position: 0 -22px;
|
458 |
+
}
|
459 |
+
|
460 |
+
.nivo-directionNav a {
|
461 |
+
display: block;
|
462 |
+
width: 30px;
|
463 |
+
height: 30px;
|
464 |
+
background: url(../images/nivo-slider/arrows.png) no-repeat;
|
465 |
+
text-indent: -9999px;
|
466 |
+
border: 0;
|
467 |
+
}
|
468 |
+
a.nivo-nextNav {
|
469 |
+
background-position: -30px 0;
|
470 |
+
right: 15px;
|
471 |
+
}
|
472 |
+
a.nivo-prevNav {
|
473 |
+
left: 15px;
|
474 |
+
}
|
475 |
+
|
476 |
+
.nivo-caption {
|
477 |
+
text-shadow: none;
|
478 |
+
font-family: Helvetica, Arial, sans-serif;
|
479 |
+
}
|
480 |
+
.nivo-caption a {
|
481 |
+
color: #efe9d1;
|
482 |
+
text-decoration: underline;
|
483 |
}
|
images/admin/tab.png
ADDED
Binary file
|
images/admin/tabs.png
ADDED
Binary file
|
images/nivo-slider/arrows.png
ADDED
Binary file
|
images/nivo-slider/bullets.png
ADDED
Binary file
|
images/nivo-slider/loading.gif
ADDED
Binary file
|
js/admin.js
CHANGED
@@ -5,9 +5,9 @@ jQuery(document).ready(function($) {
|
|
5 |
|
6 |
// Tabs
|
7 |
$('.wrap .su-pane:first').show();
|
8 |
-
$('#su-tabs').delegate('
|
9 |
$(this).addClass('su-current').siblings().removeClass('su-current')
|
10 |
-
.parents('.wrap').find('.su-pane').hide().eq($(this).index()).
|
11 |
editor.refresh();
|
12 |
});
|
13 |
});
|
5 |
|
6 |
// Tabs
|
7 |
$('.wrap .su-pane:first').show();
|
8 |
+
$('#su-tabs').delegate('a:not(.su-current)', 'click', function() {
|
9 |
$(this).addClass('su-current').siblings().removeClass('su-current')
|
10 |
+
.parents('.wrap').find('.su-pane').hide().eq($(this).index()).show();
|
11 |
editor.refresh();
|
12 |
});
|
13 |
});
|
js/jquery.nivo.slider.pack.js
ADDED
@@ -0,0 +1,67 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*
|
2 |
+
* jQuery Nivo Slider v2.5.1
|
3 |
+
* http://nivo.dev7studios.com
|
4 |
+
*
|
5 |
+
* Copyright 2011, Gilbert Pellegrom
|
6 |
+
* Free to use and abuse under the MIT license.
|
7 |
+
* http://www.opensource.org/licenses/mit-license.php
|
8 |
+
*
|
9 |
+
* March 2010
|
10 |
+
*/
|
11 |
+
|
12 |
+
(function($){var NivoSlider=function(element,options){var settings=$.extend({},$.fn.nivoSlider.defaults,options);var vars={currentSlide:0,currentImage:'',totalSlides:0,randAnim:'',running:false,paused:false,stop:false};var slider=$(element);slider.data('nivo:vars',vars);slider.css('position','relative');slider.addClass('nivoSlider');var kids=slider.children();kids.each(function(){var child=$(this);var link='';if(!child.is('img')){if(child.is('a')){child.addClass('nivo-imageLink');link=child;}
|
13 |
+
child=child.find('img:first');}
|
14 |
+
var childWidth=child.width();if(childWidth==0)childWidth=child.attr('width');var childHeight=child.height();if(childHeight==0)childHeight=child.attr('height');if(childWidth>slider.width()){slider.width(childWidth);}
|
15 |
+
if(childHeight>slider.height()){slider.height(childHeight);}
|
16 |
+
if(link!=''){link.css('display','none');}
|
17 |
+
child.css('display','none');vars.totalSlides++;});if(settings.startSlide>0){if(settings.startSlide>=vars.totalSlides)settings.startSlide=vars.totalSlides-1;vars.currentSlide=settings.startSlide;}
|
18 |
+
if($(kids[vars.currentSlide]).is('img')){vars.currentImage=$(kids[vars.currentSlide]);}else{vars.currentImage=$(kids[vars.currentSlide]).find('img:first');}
|
19 |
+
if($(kids[vars.currentSlide]).is('a')){$(kids[vars.currentSlide]).css('display','block');}
|
20 |
+
slider.css('background','url("'+vars.currentImage.attr('src')+'") no-repeat');slider.append($('<div class="nivo-caption"><p></p></div>').css({display:'none',opacity:settings.captionOpacity}));var processCaption=function(settings){var nivoCaption=$('.nivo-caption',slider);if(vars.currentImage.attr('title')!=''){var title=vars.currentImage.attr('title');if(title.substr(0,1)=='#')title=$(title).html();if(nivoCaption.css('display')=='block'){nivoCaption.find('p').fadeOut(settings.animSpeed,function(){$(this).html(title);$(this).fadeIn(settings.animSpeed);});}else{nivoCaption.find('p').html(title);}
|
21 |
+
nivoCaption.fadeIn(settings.animSpeed);}else{nivoCaption.fadeOut(settings.animSpeed);}}
|
22 |
+
processCaption(settings);var timer=0;if(!settings.manualAdvance&&kids.length>1){timer=setInterval(function(){nivoRun(slider,kids,settings,false);},settings.pauseTime);}
|
23 |
+
if(settings.directionNav){slider.append('<div class="nivo-directionNav"><a class="nivo-prevNav">'+settings.prevText+'</a><a class="nivo-nextNav">'+settings.nextText+'</a></div>');if(settings.directionNavHide){$('.nivo-directionNav',slider).hide();slider.hover(function(){$('.nivo-directionNav',slider).show();},function(){$('.nivo-directionNav',slider).hide();});}
|
24 |
+
$('a.nivo-prevNav',slider).live('click',function(){if(vars.running)return false;clearInterval(timer);timer='';vars.currentSlide-=2;nivoRun(slider,kids,settings,'prev');});$('a.nivo-nextNav',slider).live('click',function(){if(vars.running)return false;clearInterval(timer);timer='';nivoRun(slider,kids,settings,'next');});}
|
25 |
+
if(settings.controlNav){var nivoControl=$('<div class="nivo-controlNav"></div>');slider.append(nivoControl);for(var i=0;i<kids.length;i++){if(settings.controlNavThumbs){var child=kids.eq(i);if(!child.is('img')){child=child.find('img:first');}
|
26 |
+
if(settings.controlNavThumbsFromRel){nivoControl.append('<a class="nivo-control" rel="'+i+'"><img src="'+child.attr('rel')+'" alt="" /></a>');}else{nivoControl.append('<a class="nivo-control" rel="'+i+'"><img src="'+child.attr('src').replace(settings.controlNavThumbsSearch,settings.controlNavThumbsReplace)+'" alt="" /></a>');}}else{nivoControl.append('<a class="nivo-control" rel="'+i+'">'+(i+1)+'</a>');}}
|
27 |
+
$('.nivo-controlNav a:eq('+vars.currentSlide+')',slider).addClass('active');$('.nivo-controlNav a',slider).live('click',function(){if(vars.running)return false;if($(this).hasClass('active'))return false;clearInterval(timer);timer='';slider.css('background','url("'+vars.currentImage.attr('src')+'") no-repeat');vars.currentSlide=$(this).attr('rel')-1;nivoRun(slider,kids,settings,'control');});}
|
28 |
+
if(settings.keyboardNav){$(window).keypress(function(event){if(event.keyCode=='37'){if(vars.running)return false;clearInterval(timer);timer='';vars.currentSlide-=2;nivoRun(slider,kids,settings,'prev');}
|
29 |
+
if(event.keyCode=='39'){if(vars.running)return false;clearInterval(timer);timer='';nivoRun(slider,kids,settings,'next');}});}
|
30 |
+
if(settings.pauseOnHover){slider.hover(function(){vars.paused=true;clearInterval(timer);timer='';},function(){vars.paused=false;if(timer==''&&!settings.manualAdvance){timer=setInterval(function(){nivoRun(slider,kids,settings,false);},settings.pauseTime);}});}
|
31 |
+
slider.bind('nivo:animFinished',function(){vars.running=false;$(kids).each(function(){if($(this).is('a')){$(this).css('display','none');}});if($(kids[vars.currentSlide]).is('a')){$(kids[vars.currentSlide]).css('display','block');}
|
32 |
+
if(timer==''&&!vars.paused&&!settings.manualAdvance){timer=setInterval(function(){nivoRun(slider,kids,settings,false);},settings.pauseTime);}
|
33 |
+
settings.afterChange.call(this);});var createSlices=function(slider,settings,vars){for(var i=0;i<settings.slices;i++){var sliceWidth=Math.round(slider.width()/settings.slices);if(i==settings.slices-1){slider.append($('<div class="nivo-slice"></div>').css({left:(sliceWidth*i)+'px',width:(slider.width()-(sliceWidth*i))+'px',height:'0px',opacity:'0',background:'url("'+vars.currentImage.attr('src')+'") no-repeat -'+((sliceWidth+(i*sliceWidth))-sliceWidth)+'px 0%'}));}else{slider.append($('<div class="nivo-slice"></div>').css({left:(sliceWidth*i)+'px',width:sliceWidth+'px',height:'0px',opacity:'0',background:'url("'+vars.currentImage.attr('src')+'") no-repeat -'+((sliceWidth+(i*sliceWidth))-sliceWidth)+'px 0%'}));}}}
|
34 |
+
var createBoxes=function(slider,settings,vars){var boxWidth=Math.round(slider.width()/settings.boxCols);var boxHeight=Math.round(slider.height()/settings.boxRows);for(var rows=0;rows<settings.boxRows;rows++){for(var cols=0;cols<settings.boxCols;cols++){if(cols==settings.boxCols-1){slider.append($('<div class="nivo-box"></div>').css({opacity:0,left:(boxWidth*cols)+'px',top:(boxHeight*rows)+'px',width:(slider.width()-(boxWidth*cols))+'px',height:boxHeight+'px',background:'url("'+vars.currentImage.attr('src')+'") no-repeat -'+((boxWidth+(cols*boxWidth))-boxWidth)+'px -'+((boxHeight+(rows*boxHeight))-boxHeight)+'px'}));}else{slider.append($('<div class="nivo-box"></div>').css({opacity:0,left:(boxWidth*cols)+'px',top:(boxHeight*rows)+'px',width:boxWidth+'px',height:boxHeight+'px',background:'url("'+vars.currentImage.attr('src')+'") no-repeat -'+((boxWidth+(cols*boxWidth))-boxWidth)+'px -'+((boxHeight+(rows*boxHeight))-boxHeight)+'px'}));}}}}
|
35 |
+
var nivoRun=function(slider,kids,settings,nudge){var vars=slider.data('nivo:vars');if(vars&&(vars.currentSlide==vars.totalSlides-1)){settings.lastSlide.call(this);}
|
36 |
+
if((!vars||vars.stop)&&!nudge)return false;settings.beforeChange.call(this);if(!nudge){slider.css('background','url("'+vars.currentImage.attr('src')+'") no-repeat');}else{if(nudge=='prev'){slider.css('background','url("'+vars.currentImage.attr('src')+'") no-repeat');}
|
37 |
+
if(nudge=='next'){slider.css('background','url("'+vars.currentImage.attr('src')+'") no-repeat');}}
|
38 |
+
vars.currentSlide++;if(vars.currentSlide==vars.totalSlides){vars.currentSlide=0;settings.slideshowEnd.call(this);}
|
39 |
+
if(vars.currentSlide<0)vars.currentSlide=(vars.totalSlides-1);if($(kids[vars.currentSlide]).is('img')){vars.currentImage=$(kids[vars.currentSlide]);}else{vars.currentImage=$(kids[vars.currentSlide]).find('img:first');}
|
40 |
+
if(settings.controlNav){$('.nivo-controlNav a',slider).removeClass('active');$('.nivo-controlNav a:eq('+vars.currentSlide+')',slider).addClass('active');}
|
41 |
+
processCaption(settings);$('.nivo-slice',slider).remove();$('.nivo-box',slider).remove();if(settings.effect=='random'){var anims=new Array('sliceDownRight','sliceDownLeft','sliceUpRight','sliceUpLeft','sliceUpDown','sliceUpDownLeft','fold','fade','boxRandom','boxRain','boxRainReverse','boxRainGrow','boxRainGrowReverse');vars.randAnim=anims[Math.floor(Math.random()*(anims.length+1))];if(vars.randAnim==undefined)vars.randAnim='fade';}
|
42 |
+
if(settings.effect.indexOf(',')!=-1){var anims=settings.effect.split(',');vars.randAnim=anims[Math.floor(Math.random()*(anims.length))];if(vars.randAnim==undefined)vars.randAnim='fade';}
|
43 |
+
vars.running=true;if(settings.effect=='sliceDown'||settings.effect=='sliceDownRight'||vars.randAnim=='sliceDownRight'||settings.effect=='sliceDownLeft'||vars.randAnim=='sliceDownLeft'){createSlices(slider,settings,vars);var timeBuff=0;var i=0;var slices=$('.nivo-slice',slider);if(settings.effect=='sliceDownLeft'||vars.randAnim=='sliceDownLeft')slices=$('.nivo-slice',slider)._reverse();slices.each(function(){var slice=$(this);slice.css({'top':'0px'});if(i==settings.slices-1){setTimeout(function(){slice.animate({height:'100%',opacity:'1.0'},settings.animSpeed,'',function(){slider.trigger('nivo:animFinished');});},(100+timeBuff));}else{setTimeout(function(){slice.animate({height:'100%',opacity:'1.0'},settings.animSpeed);},(100+timeBuff));}
|
44 |
+
timeBuff+=50;i++;});}
|
45 |
+
else if(settings.effect=='sliceUp'||settings.effect=='sliceUpRight'||vars.randAnim=='sliceUpRight'||settings.effect=='sliceUpLeft'||vars.randAnim=='sliceUpLeft'){createSlices(slider,settings,vars);var timeBuff=0;var i=0;var slices=$('.nivo-slice',slider);if(settings.effect=='sliceUpLeft'||vars.randAnim=='sliceUpLeft')slices=$('.nivo-slice',slider)._reverse();slices.each(function(){var slice=$(this);slice.css({'bottom':'0px'});if(i==settings.slices-1){setTimeout(function(){slice.animate({height:'100%',opacity:'1.0'},settings.animSpeed,'',function(){slider.trigger('nivo:animFinished');});},(100+timeBuff));}else{setTimeout(function(){slice.animate({height:'100%',opacity:'1.0'},settings.animSpeed);},(100+timeBuff));}
|
46 |
+
timeBuff+=50;i++;});}
|
47 |
+
else if(settings.effect=='sliceUpDown'||settings.effect=='sliceUpDownRight'||vars.randAnim=='sliceUpDown'||settings.effect=='sliceUpDownLeft'||vars.randAnim=='sliceUpDownLeft'){createSlices(slider,settings,vars);var timeBuff=0;var i=0;var v=0;var slices=$('.nivo-slice',slider);if(settings.effect=='sliceUpDownLeft'||vars.randAnim=='sliceUpDownLeft')slices=$('.nivo-slice',slider)._reverse();slices.each(function(){var slice=$(this);if(i==0){slice.css('top','0px');i++;}else{slice.css('bottom','0px');i=0;}
|
48 |
+
if(v==settings.slices-1){setTimeout(function(){slice.animate({height:'100%',opacity:'1.0'},settings.animSpeed,'',function(){slider.trigger('nivo:animFinished');});},(100+timeBuff));}else{setTimeout(function(){slice.animate({height:'100%',opacity:'1.0'},settings.animSpeed);},(100+timeBuff));}
|
49 |
+
timeBuff+=50;v++;});}
|
50 |
+
else if(settings.effect=='fold'||vars.randAnim=='fold'){createSlices(slider,settings,vars);var timeBuff=0;var i=0;$('.nivo-slice',slider).each(function(){var slice=$(this);var origWidth=slice.width();slice.css({top:'0px',height:'100%',width:'0px'});if(i==settings.slices-1){setTimeout(function(){slice.animate({width:origWidth,opacity:'1.0'},settings.animSpeed,'',function(){slider.trigger('nivo:animFinished');});},(100+timeBuff));}else{setTimeout(function(){slice.animate({width:origWidth,opacity:'1.0'},settings.animSpeed);},(100+timeBuff));}
|
51 |
+
timeBuff+=50;i++;});}
|
52 |
+
else if(settings.effect=='fade'||vars.randAnim=='fade'){createSlices(slider,settings,vars);var firstSlice=$('.nivo-slice:first',slider);firstSlice.css({'height':'100%','width':slider.width()+'px'});firstSlice.animate({opacity:'1.0'},(settings.animSpeed*2),'',function(){slider.trigger('nivo:animFinished');});}
|
53 |
+
else if(settings.effect=='slideInRight'||vars.randAnim=='slideInRight'){createSlices(slider,settings,vars);var firstSlice=$('.nivo-slice:first',slider);firstSlice.css({'height':'100%','width':'0px','opacity':'1'});firstSlice.animate({width:slider.width()+'px'},(settings.animSpeed*2),'',function(){slider.trigger('nivo:animFinished');});}
|
54 |
+
else if(settings.effect=='slideInLeft'||vars.randAnim=='slideInLeft'){createSlices(slider,settings,vars);var firstSlice=$('.nivo-slice:first',slider);firstSlice.css({'height':'100%','width':'0px','opacity':'1','left':'','right':'0px'});firstSlice.animate({width:slider.width()+'px'},(settings.animSpeed*2),'',function(){firstSlice.css({'left':'0px','right':''});slider.trigger('nivo:animFinished');});}
|
55 |
+
else if(settings.effect=='boxRandom'||vars.randAnim=='boxRandom'){createBoxes(slider,settings,vars);var totalBoxes=settings.boxCols*settings.boxRows;var i=0;var timeBuff=0;var boxes=shuffle($('.nivo-box',slider));boxes.each(function(){var box=$(this);if(i==totalBoxes-1){setTimeout(function(){box.animate({opacity:'1'},settings.animSpeed,'',function(){slider.trigger('nivo:animFinished');});},(100+timeBuff));}else{setTimeout(function(){box.animate({opacity:'1'},settings.animSpeed);},(100+timeBuff));}
|
56 |
+
timeBuff+=20;i++;});}
|
57 |
+
else if(settings.effect=='boxRain'||vars.randAnim=='boxRain'||settings.effect=='boxRainReverse'||vars.randAnim=='boxRainReverse'||settings.effect=='boxRainGrow'||vars.randAnim=='boxRainGrow'||settings.effect=='boxRainGrowReverse'||vars.randAnim=='boxRainGrowReverse'){createBoxes(slider,settings,vars);var totalBoxes=settings.boxCols*settings.boxRows;var i=0;var timeBuff=0;var rowIndex=0;var colIndex=0;var box2Darr=new Array();box2Darr[rowIndex]=new Array();var boxes=$('.nivo-box',slider);if(settings.effect=='boxRainReverse'||vars.randAnim=='boxRainReverse'||settings.effect=='boxRainGrowReverse'||vars.randAnim=='boxRainGrowReverse'){boxes=$('.nivo-box',slider)._reverse();}
|
58 |
+
boxes.each(function(){box2Darr[rowIndex][colIndex]=$(this);colIndex++;if(colIndex==settings.boxCols){rowIndex++;colIndex=0;box2Darr[rowIndex]=new Array();}});for(var cols=0;cols<(settings.boxCols*2);cols++){var prevCol=cols;for(var rows=0;rows<settings.boxRows;rows++){if(prevCol>=0&&prevCol<settings.boxCols){(function(row,col,time,i,totalBoxes){var box=$(box2Darr[row][col]);var w=box.width();var h=box.height();if(settings.effect=='boxRainGrow'||vars.randAnim=='boxRainGrow'||settings.effect=='boxRainGrowReverse'||vars.randAnim=='boxRainGrowReverse'){box.width(0).height(0);}
|
59 |
+
if(i==totalBoxes-1){setTimeout(function(){box.animate({opacity:'1',width:w,height:h},settings.animSpeed/1.3,'',function(){slider.trigger('nivo:animFinished');});},(100+time));}else{setTimeout(function(){box.animate({opacity:'1',width:w,height:h},settings.animSpeed/1.3);},(100+time));}})(rows,prevCol,timeBuff,i,totalBoxes);i++;}
|
60 |
+
prevCol--;}
|
61 |
+
timeBuff+=100;}}}
|
62 |
+
var shuffle=function(arr){for(var j,x,i=arr.length;i;j=parseInt(Math.random()*i),x=arr[--i],arr[i]=arr[j],arr[j]=x);return arr;}
|
63 |
+
var trace=function(msg){if(this.console&&typeof console.log!="undefined")
|
64 |
+
console.log(msg);}
|
65 |
+
this.stop=function(){if(!$(element).data('nivo:vars').stop){$(element).data('nivo:vars').stop=true;trace('Stop Slider');}}
|
66 |
+
this.start=function(){if($(element).data('nivo:vars').stop){$(element).data('nivo:vars').stop=false;trace('Start Slider');}}
|
67 |
+
settings.afterLoad.call(this);return this;};$.fn.nivoSlider=function(options){return this.each(function(key,value){var element=$(this);if(element.data('nivoslider'))return element.data('nivoslider');var nivoslider=new NivoSlider(this,options);element.data('nivoslider',nivoslider);});};$.fn.nivoSlider.defaults={effect:'random',slices:15,boxCols:8,boxRows:4,animSpeed:500,pauseTime:3000,startSlide:0,directionNav:true,directionNavHide:true,controlNav:true,controlNavThumbs:false,controlNavThumbsFromRel:false,controlNavThumbsSearch:'.jpg',controlNavThumbsReplace:'_thumb.jpg',keyboardNav:true,pauseOnHover:true,manualAdvance:false,captionOpacity:0.8,prevText:'Prev',nextText:'Next',beforeChange:function(){},afterChange:function(){},slideshowEnd:function(){},lastSlide:function(){},afterLoad:function(){}};$.fn._reverse=[].reverse;})(jQuery);
|
languages/shortcodes-ultimate-ru_RU.mo
CHANGED
Binary file
|
languages/shortcodes-ultimate-ru_RU.po
CHANGED
@@ -2,8 +2,8 @@ msgid ""
|
|
2 |
msgstr ""
|
3 |
"Project-Id-Version: gn_themes\n"
|
4 |
"Report-Msgid-Bugs-To: \n"
|
5 |
-
"POT-Creation-Date: 2011-04-
|
6 |
-
"PO-Revision-Date: 2011-04-
|
7 |
"Last-Translator: Vladimir Anokhin <ano.vladimir@gmail.com>\n"
|
8 |
"Language-Team: \n"
|
9 |
"MIME-Version: 1.0\n"
|
@@ -14,24 +14,24 @@ msgstr ""
|
|
14 |
"X-Poedit-SourceCharset: utf-8\n"
|
15 |
"X-Poedit-SearchPath-0: .\n"
|
16 |
|
17 |
-
#: shortcodes-ultimate.php:
|
18 |
#: lib/admin.php:23
|
19 |
msgid "Shortcodes Ultimate"
|
20 |
msgstr "Шорткоды"
|
21 |
|
22 |
-
#: shortcodes-ultimate.php:
|
23 |
msgid "Vladimir Anokhin"
|
24 |
msgstr "Владимир Анохин"
|
25 |
|
26 |
-
#: shortcodes-ultimate.php:
|
27 |
msgid "Provides support for many easy to use shortcodes"
|
28 |
msgstr "Предоставляет поддержку множества полезных шорткодов"
|
29 |
|
30 |
-
#: shortcodes-ultimate.php:
|
31 |
msgid "Settings saved"
|
32 |
msgstr "Настройки сохранены"
|
33 |
|
34 |
-
#: shortcodes-ultimate.php:
|
35 |
msgid "Custom CSS saved"
|
36 |
msgstr "Произвольные стили сохранены"
|
37 |
|
@@ -176,6 +176,7 @@ msgstr "Скрытый текст"
|
|
176 |
#: lib/admin.php:143
|
177 |
#: lib/admin.php:168
|
178 |
#: lib/admin.php:203
|
|
|
179 |
msgid "optional"
|
180 |
msgstr "необяз."
|
181 |
|
@@ -224,6 +225,14 @@ msgstr "Простая таблица"
|
|
224 |
msgid "From CSV"
|
225 |
msgstr "Из CSV-файла"
|
226 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
227 |
#: lib/shortcodes.php:96
|
228 |
msgid "Top"
|
229 |
msgstr "Вверх"
|
@@ -236,6 +245,10 @@ msgstr "Заголовок блока"
|
|
236 |
msgid "Please specify media url"
|
237 |
msgstr "Укажите ссылку на медиа"
|
238 |
|
|
|
|
|
|
|
|
|
239 |
#~ msgid "Want to support author? Just share this link!"
|
240 |
#~ msgstr "Хотите поддержать автора? Просто опубликйте ссылку!"
|
241 |
|
2 |
msgstr ""
|
3 |
"Project-Id-Version: gn_themes\n"
|
4 |
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2011-04-27 23:53+0300\n"
|
6 |
+
"PO-Revision-Date: 2011-04-27 23:53+0300\n"
|
7 |
"Last-Translator: Vladimir Anokhin <ano.vladimir@gmail.com>\n"
|
8 |
"Language-Team: \n"
|
9 |
"MIME-Version: 1.0\n"
|
14 |
"X-Poedit-SourceCharset: utf-8\n"
|
15 |
"X-Poedit-SearchPath-0: .\n"
|
16 |
|
17 |
+
#: shortcodes-ultimate.php:155
|
18 |
#: lib/admin.php:23
|
19 |
msgid "Shortcodes Ultimate"
|
20 |
msgstr "Шорткоды"
|
21 |
|
22 |
+
#: shortcodes-ultimate.php:155
|
23 |
msgid "Vladimir Anokhin"
|
24 |
msgstr "Владимир Анохин"
|
25 |
|
26 |
+
#: shortcodes-ultimate.php:155
|
27 |
msgid "Provides support for many easy to use shortcodes"
|
28 |
msgstr "Предоставляет поддержку множества полезных шорткодов"
|
29 |
|
30 |
+
#: shortcodes-ultimate.php:239
|
31 |
msgid "Settings saved"
|
32 |
msgstr "Настройки сохранены"
|
33 |
|
34 |
+
#: shortcodes-ultimate.php:244
|
35 |
msgid "Custom CSS saved"
|
36 |
msgstr "Произвольные стили сохранены"
|
37 |
|
176 |
#: lib/admin.php:143
|
177 |
#: lib/admin.php:168
|
178 |
#: lib/admin.php:203
|
179 |
+
#: lib/admin.php:213
|
180 |
msgid "optional"
|
181 |
msgstr "необяз."
|
182 |
|
225 |
msgid "From CSV"
|
226 |
msgstr "Из CSV-файла"
|
227 |
|
228 |
+
#: lib/admin.php:213
|
229 |
+
msgid "1 second"
|
230 |
+
msgstr "1 секунда"
|
231 |
+
|
232 |
+
#: lib/admin.php:218
|
233 |
+
msgid "See filter IDs"
|
234 |
+
msgstr "Смотреть ID фильтров"
|
235 |
+
|
236 |
#: lib/shortcodes.php:96
|
237 |
msgid "Top"
|
238 |
msgstr "Вверх"
|
245 |
msgid "Please specify media url"
|
246 |
msgstr "Укажите ссылку на медиа"
|
247 |
|
248 |
+
#: lib/shortcodes.php:481
|
249 |
+
msgid "no attached images, or only one attached image"
|
250 |
+
msgstr "не найдены загруженные изображения, или изображение всего одно"
|
251 |
+
|
252 |
#~ msgid "Want to support author? Just share this link!"
|
253 |
#~ msgstr "Хотите поддержать автора? Просто опубликйте ссылку!"
|
254 |
|
lib/admin.php
CHANGED
@@ -67,11 +67,11 @@
|
|
67 |
|
68 |
<?php su_save_notification(); ?>
|
69 |
|
70 |
-
<
|
71 |
-
<
|
72 |
-
<
|
73 |
-
<
|
74 |
-
</
|
75 |
<div class="su-pane">
|
76 |
<form action="" method="post">
|
77 |
<table class="fixed">
|
@@ -163,7 +163,7 @@
|
|
163 |
<td>bg="#HEX"<br/>color="#HEX"</td>
|
164 |
<td>[highlight bg="#fc0" color="#000"] <?php _e( 'Content', 'shortcodes-ultimate' ); ?> [/highlight]</td>
|
165 |
</tr>
|
166 |
-
<tr
|
167 |
<td>button</td>
|
168 |
<td>link<br/>color="#HEX"<br/>size="1-12"<br/>style="1|2|3|4"<br/>dark (<?php _e( 'optional', 'shortcodes-ultimate' ); ?>)<br/>square (<?php _e( 'optional', 'shortcodes-ultimate' ); ?>)<br/>icon (<?php _e( 'optional', 'shortcodes-ultimate' ); ?>)</td>
|
169 |
<td>[button link="#" color="#b00" size="3" style="3" dark="1" square="1" icon="image.png"] <?php _e( 'Button text', 'shortcodes-ultimate' ); ?> [/button]</td>
|
@@ -188,7 +188,7 @@
|
|
188 |
<td>color="#HEX"</td>
|
189 |
<td>[note color="#D1F26D"] <?php _e( 'Content', 'shortcodes-ultimate' ); ?> [/note]</td>
|
190 |
</tr>
|
191 |
-
<tr
|
192 |
<td>list</td>
|
193 |
<td>style="star|arrow|check|cross|thumbs|link|gear|time|note|plus|guard|event|idea|settings|twitter"</td>
|
194 |
<td>[list style="check"] <ul> <li> <?php _e( 'List item', 'shortcodes-ultimate' ); ?> </li> </ul> [/list]</td>
|
@@ -198,16 +198,26 @@
|
|
198 |
<td>size="1-2|1-3|1-4|1-5|1-6|2-3|3-4|2-5|3-5|4-5|5-6"<br/>last (<?php _e( 'add this to last columns', 'shortcodes-ultimate' ); ?>)</td>
|
199 |
<td>[column size="1-2"] <?php _e( 'Content', 'shortcodes-ultimate' ); ?> [/column]<br/>[column size="1-2" last="1"] <?php _e( 'Content', 'shortcodes-ultimate' ); ?> [/column]</td>
|
200 |
</tr>
|
201 |
-
<tr
|
202 |
<td>table</td>
|
203 |
<td>style="1|2|3"<br/>file (<?php _e( 'optional', 'shortcodes-ultimate' ); ?>)</td>
|
204 |
<td><p><strong><?php _e( 'Plain table', 'shortcodes-ultimate' ); ?></strong><br/>[table style="1"] <table> … <table> [/table]</p><p><strong><?php _e( 'From CSV', 'shortcodes-ultimate' ); ?></strong><br/>[table style="1" file="http://example.com/file.csv"] [/table]</p></td>
|
205 |
</tr>
|
206 |
-
<tr
|
207 |
<td>media</td>
|
208 |
<td>url<br/>width<br/>height</td>
|
209 |
<td>[media url="http://www.youtube.com/watch?v=2c2EEacfC1M"]<br/>[media url="http://vimeo.com/15069551"]<br/>[media url="video.mp4"]<br/>[media url="video.flv"]<br/>[media url="audio.mp3"]<br/>[media url="image.jpg"]</td>
|
210 |
</tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
211 |
</table>
|
212 |
</div>
|
213 |
</div>
|
67 |
|
68 |
<?php su_save_notification(); ?>
|
69 |
|
70 |
+
<div id="su-tabs">
|
71 |
+
<a class="su-current"><span><?php _e( 'General settings', 'shortcodes-ultimate' ); ?></span></a>
|
72 |
+
<a><span><?php _e( 'Custom CSS', 'shortcodes-ultimate' ); ?></span></a>
|
73 |
+
<a><span><?php _e( 'Available shortcodes', 'shortcodes-ultimate' ); ?></span></a>
|
74 |
+
</div>
|
75 |
<div class="su-pane">
|
76 |
<form action="" method="post">
|
77 |
<table class="fixed">
|
163 |
<td>bg="#HEX"<br/>color="#HEX"</td>
|
164 |
<td>[highlight bg="#fc0" color="#000"] <?php _e( 'Content', 'shortcodes-ultimate' ); ?> [/highlight]</td>
|
165 |
</tr>
|
166 |
+
<tr>
|
167 |
<td>button</td>
|
168 |
<td>link<br/>color="#HEX"<br/>size="1-12"<br/>style="1|2|3|4"<br/>dark (<?php _e( 'optional', 'shortcodes-ultimate' ); ?>)<br/>square (<?php _e( 'optional', 'shortcodes-ultimate' ); ?>)<br/>icon (<?php _e( 'optional', 'shortcodes-ultimate' ); ?>)</td>
|
169 |
<td>[button link="#" color="#b00" size="3" style="3" dark="1" square="1" icon="image.png"] <?php _e( 'Button text', 'shortcodes-ultimate' ); ?> [/button]</td>
|
188 |
<td>color="#HEX"</td>
|
189 |
<td>[note color="#D1F26D"] <?php _e( 'Content', 'shortcodes-ultimate' ); ?> [/note]</td>
|
190 |
</tr>
|
191 |
+
<tr>
|
192 |
<td>list</td>
|
193 |
<td>style="star|arrow|check|cross|thumbs|link|gear|time|note|plus|guard|event|idea|settings|twitter"</td>
|
194 |
<td>[list style="check"] <ul> <li> <?php _e( 'List item', 'shortcodes-ultimate' ); ?> </li> </ul> [/list]</td>
|
198 |
<td>size="1-2|1-3|1-4|1-5|1-6|2-3|3-4|2-5|3-5|4-5|5-6"<br/>last (<?php _e( 'add this to last columns', 'shortcodes-ultimate' ); ?>)</td>
|
199 |
<td>[column size="1-2"] <?php _e( 'Content', 'shortcodes-ultimate' ); ?> [/column]<br/>[column size="1-2" last="1"] <?php _e( 'Content', 'shortcodes-ultimate' ); ?> [/column]</td>
|
200 |
</tr>
|
201 |
+
<tr>
|
202 |
<td>table</td>
|
203 |
<td>style="1|2|3"<br/>file (<?php _e( 'optional', 'shortcodes-ultimate' ); ?>)</td>
|
204 |
<td><p><strong><?php _e( 'Plain table', 'shortcodes-ultimate' ); ?></strong><br/>[table style="1"] <table> … <table> [/table]</p><p><strong><?php _e( 'From CSV', 'shortcodes-ultimate' ); ?></strong><br/>[table style="1" file="http://example.com/file.csv"] [/table]</p></td>
|
205 |
</tr>
|
206 |
+
<tr>
|
207 |
<td>media</td>
|
208 |
<td>url<br/>width<br/>height</td>
|
209 |
<td>[media url="http://www.youtube.com/watch?v=2c2EEacfC1M"]<br/>[media url="http://vimeo.com/15069551"]<br/>[media url="video.mp4"]<br/>[media url="video.flv"]<br/>[media url="audio.mp3"]<br/>[media url="image.jpg"]</td>
|
210 |
</tr>
|
211 |
+
<tr class="su-new-shortcode">
|
212 |
+
<td>nivo_slider</td>
|
213 |
+
<td>width<br/>height<br/>link="file|attachment" (<?php _e( 'optional', 'shortcodes-ultimate' ); ?>)<br/>speed (1000 = <?php _e( '1 second', 'shortcodes-ultimate' ); ?>)<br/>delay (1000 = <?php _e( '1 second', 'shortcodes-ultimate' ); ?>)<br/>p - post ID (<?php _e( 'optional', 'shortcodes-ultimate' ); ?>)<br/>effect="random|boxRandom|fold|fade"</td>
|
214 |
+
<td>[nivo_slider]<br/>[nivo_slider width="640" height="400" link="file" effect="boxRandom"]</td>
|
215 |
+
</tr>
|
216 |
+
<tr class="su-new-shortcode">
|
217 |
+
<td>photoshop</td>
|
218 |
+
<td>image (url)<br/>width<br/>height<br/>crop="0|1"<br/>quality="0-100"<br/>sharpen="0|1"<br/>filter="%filter_id%"<br/><a href="http://www.binarymoon.co.uk/demo/timthumb-filters/" target="_blank"><?php _e( 'See filter IDs', 'shortcodes-ultimate' ); ?></a></td>
|
219 |
+
<td>[photoshop image="image.jpg" width="400" height="300" filter="2"]</td>
|
220 |
+
</tr>
|
221 |
</table>
|
222 |
</div>
|
223 |
</div>
|
lib/shortcodes.php
CHANGED
@@ -382,4 +382,105 @@
|
|
382 |
return $return;
|
383 |
}
|
384 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
385 |
?>
|
382 |
return $return;
|
383 |
}
|
384 |
|
385 |
+
/**
|
386 |
+
* Shortcode: photoshop
|
387 |
+
*
|
388 |
+
* @param array $atts Shortcode attributes
|
389 |
+
* @param string $content
|
390 |
+
* @return string Output html
|
391 |
+
*/
|
392 |
+
function su_photoshop_shortcode( $atts, $content = null ) {
|
393 |
+
extract( shortcode_atts( array(
|
394 |
+
'image' => false,
|
395 |
+
'width' => 200,
|
396 |
+
'height' => 100,
|
397 |
+
'crop' => 1,
|
398 |
+
'quality' => 100,
|
399 |
+
'filter' => 1,
|
400 |
+
'sharpen' => 0
|
401 |
+
), $atts ) );
|
402 |
+
|
403 |
+
return '<img src="' . su_plugin_url() . '/lib/timthumb.php?src=' . $image . '&w=' . $width . '&h=' . $height . '&zc=' . $crop . '&q=' . $quality . '&f=' . $filter . '&s=' . $sharpen . '" width="' . $width . '" height="' . $height . '" alt="" />';
|
404 |
+
}
|
405 |
+
|
406 |
+
/**
|
407 |
+
* Shortcode: nivo_slider
|
408 |
+
*
|
409 |
+
* @param array $atts Shortcode attributes
|
410 |
+
* @param string $content
|
411 |
+
* @return string Output html
|
412 |
+
*/
|
413 |
+
function su_nivo_slider_shortcode( $atts, $content = null ) {
|
414 |
+
extract( shortcode_atts( array(
|
415 |
+
'width' => 600,
|
416 |
+
'height' => 300,
|
417 |
+
'link' => false,
|
418 |
+
'effect' => 'random',
|
419 |
+
'speed' => 600,
|
420 |
+
'delay' => 3000,
|
421 |
+
'p' => false
|
422 |
+
), $atts ) );
|
423 |
+
|
424 |
+
global $post;
|
425 |
+
$post_id = ( $p ) ? $p : $post->ID;
|
426 |
+
|
427 |
+
$args = array(
|
428 |
+
'post_type' => 'attachment',
|
429 |
+
'numberposts' => -1,
|
430 |
+
'order' => 'ASC',
|
431 |
+
'post_status' => null,
|
432 |
+
'post_parent' => $post_id
|
433 |
+
);
|
434 |
+
|
435 |
+
// Get attachments
|
436 |
+
$attachments = get_posts( $args );
|
437 |
+
|
438 |
+
// If has attachments
|
439 |
+
if ( count( $attachments ) > 1 ) {
|
440 |
+
|
441 |
+
$return = '
|
442 |
+
<script type="text/javascript">
|
443 |
+
jQuery(window).load(function() {
|
444 |
+
jQuery("#su-nivo-slider").nivoSlider({
|
445 |
+
effect: "' . $effect . '",
|
446 |
+
animSpeed: ' . $speed . ',
|
447 |
+
pauseTime: ' . $delay . '
|
448 |
+
});
|
449 |
+
});
|
450 |
+
</script>
|
451 |
+
<style type="text/css">
|
452 |
+
#su-nivo-slider {width:' . $width . 'px;height:' . $height . 'px}
|
453 |
+
</style>
|
454 |
+
';
|
455 |
+
|
456 |
+
$return .= '<div id="su-nivo-slider">';
|
457 |
+
foreach ( $attachments as $attachment ) {
|
458 |
+
$title = apply_filters( 'the_title', $attachment->post_title );
|
459 |
+
$image = wp_get_attachment_image_src( $attachment->ID, 'full', false );
|
460 |
+
|
461 |
+
// Link to file
|
462 |
+
if ( $link == 'file' ) {
|
463 |
+
$return .= '<a href="' . $image[0] . '" title="' . $title . '"><img src="' . su_plugin_url() . '/lib/timthumb.php?src=' . $image[0] . '&w=' . $width . '&h=' . $height . '&q=100&zc=1" width="' . $width . '" height="' . $height . '" alt="' . $title . '" /></a>' . "\n";
|
464 |
+
}
|
465 |
+
|
466 |
+
// Link to attachment page
|
467 |
+
elseif ( $link == 'attachment' ) {
|
468 |
+
$return .= '<a href="' . get_permalink( $attachment->ID ) . '" title="' . $title . '"><img src="' . su_plugin_url() . '/lib/timthumb.php?src=' . $image[0] . '&w=' . $width . '&h=' . $height . '&q=100&zc=1" width="' . $width . '" height="' . $height . '" alt="' . $title . '" /></a>' . "\n";
|
469 |
+
}
|
470 |
+
|
471 |
+
// No link
|
472 |
+
else {
|
473 |
+
$return .= '<img src="' . su_plugin_url() . '/lib/timthumb.php?src=' . $image[0] . '&w=' . $width . '&h=' . $height . '&q=100&zc=1" width="' . $width . '" height="' . $height . '" alt="' . $title . '" />' . "\n";
|
474 |
+
}
|
475 |
+
}
|
476 |
+
$return .= '</div>';
|
477 |
+
}
|
478 |
+
|
479 |
+
// No attachments
|
480 |
+
else {
|
481 |
+
$return = '<p class="su-error"><strong>Nivo slider:</strong> ' . __( 'no attached images, or only one attached image', 'shortcodes-ultimate' ) . '…</p>';
|
482 |
+
}
|
483 |
+
|
484 |
+
return $return;
|
485 |
+
}
|
486 |
?>
|
readme.txt
CHANGED
@@ -1,16 +1,21 @@
|
|
1 |
=== Plugin Name ===
|
2 |
Contributors: gn_themes
|
3 |
Donate link: http://ilovecode.ru/
|
4 |
-
Tags: shortcode, shortcodes, short code, shortcodes, tab, tabs, button, buttons, jquery, box, boxes, toggle, spoiler, column, columns, services, service, pullquote, list, lists, frame, images, image, links, fancy, fancy link, fancy links, fancy buttons, jquery tabs, accordeon
|
5 |
Requires at least: 3.0
|
6 |
Tested up to: 3.1
|
7 |
-
Stable tag: 1.
|
8 |
|
9 |
Provides support for multiple useful shortcodes
|
10 |
|
11 |
|
12 |
== Description ==
|
13 |
|
|
|
|
|
|
|
|
|
|
|
14 |
With this plugin you can easily add buttons, dividers, spacers, boxes, notes and much more
|
15 |
= Complete list of available shortcodes =
|
16 |
* Heading
|
@@ -31,6 +36,8 @@ With this plugin you can easily add buttons, dividers, spacers, boxes, notes and
|
|
31 |
* Column
|
32 |
* Table
|
33 |
* Media
|
|
|
|
|
34 |
|
35 |
Bug report / contact author: http://ilovecode.ru/?p=122
|
36 |
My twitter: http://twitter.com/gn_themes
|
@@ -64,6 +71,11 @@ In your dashboard
|
|
64 |
|
65 |
== Changelog ==
|
66 |
|
|
|
|
|
|
|
|
|
|
|
67 |
= 1.6.1 =
|
68 |
* Small fixes
|
69 |
* Added donation forms
|
1 |
=== Plugin Name ===
|
2 |
Contributors: gn_themes
|
3 |
Donate link: http://ilovecode.ru/
|
4 |
+
Tags: shortcode, shortcodes, short code, shortcodes, tab, tabs, button, buttons, jquery, box, boxes, toggle, spoiler, column, columns, services, service, pullquote, list, lists, frame, images, image, links, fancy, fancy link, fancy links, fancy buttons, jquery tabs, accordeon, slider, nivo, nivo slider, plugin, admin, photoshop, gallery
|
5 |
Requires at least: 3.0
|
6 |
Tested up to: 3.1
|
7 |
+
Stable tag: 1.7.0
|
8 |
|
9 |
Provides support for multiple useful shortcodes
|
10 |
|
11 |
|
12 |
== Description ==
|
13 |
|
14 |
+
= In this version =
|
15 |
+
* Improved settings page
|
16 |
+
* Added shortcode nivo_slider
|
17 |
+
* Added shortcode photoshop
|
18 |
+
|
19 |
With this plugin you can easily add buttons, dividers, spacers, boxes, notes and much more
|
20 |
= Complete list of available shortcodes =
|
21 |
* Heading
|
36 |
* Column
|
37 |
* Table
|
38 |
* Media
|
39 |
+
* Nivo slider
|
40 |
+
* Photoshop
|
41 |
|
42 |
Bug report / contact author: http://ilovecode.ru/?p=122
|
43 |
My twitter: http://twitter.com/gn_themes
|
71 |
|
72 |
== Changelog ==
|
73 |
|
74 |
+
= 1.7.0 =
|
75 |
+
* Improved settings page design
|
76 |
+
* Added shortcode nivo_slider
|
77 |
+
* Added shortcode photoshop
|
78 |
+
|
79 |
= 1.6.1 =
|
80 |
* Small fixes
|
81 |
* Added donation forms
|
shortcodes-ultimate.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/*
|
4 |
Plugin Name: Shortcodes Ultimate
|
5 |
Plugin URI: http://ilovecode.ru/?p=122
|
6 |
-
Version: 1.
|
7 |
Author: Vladimir Anokhin
|
8 |
Author URI: http://ilovecode.ru/
|
9 |
Description: Provides support for many easy to use shortcodes
|
@@ -48,12 +48,14 @@
|
|
48 |
// Register styles
|
49 |
wp_register_style( 'shortcodes-ultimate', su_plugin_url() . '/css/style.css', false, su_get_version(), 'all' );
|
50 |
wp_register_style( 'shortcodes-ultimate-admin', su_plugin_url() . '/css/admin.css', false, su_get_version(), 'all' );
|
|
|
51 |
wp_register_style( 'codemirror', su_plugin_url() . '/css/codemirror.css', false, su_get_version(), 'all' );
|
52 |
wp_register_style( 'codemirror-css', su_plugin_url() . '/css/codemirror-css.css', false, su_get_version(), 'all' );
|
53 |
|
54 |
// Register scripts
|
55 |
wp_register_script( 'shortcodes-ultimate', su_plugin_url() . '/js/init.js', false, su_get_version(), false );
|
56 |
wp_register_script( 'shortcodes-ultimate-admin', su_plugin_url() . '/js/admin.js', false, su_get_version(), false );
|
|
|
57 |
wp_register_script( 'codemirror', su_plugin_url() . '/js/codemirror.js', false, su_get_version(), false );
|
58 |
wp_register_script( 'codemirror-css', su_plugin_url() . '/js/codemirror-css.js', false, su_get_version(), false );
|
59 |
wp_register_script( 'jwplayer', su_plugin_url() . '/js/jwplayer.js', false, su_get_version(), false );
|
@@ -62,11 +64,13 @@
|
|
62 |
if ( !is_admin() ) {
|
63 |
|
64 |
// Enqueue styles
|
|
|
65 |
wp_enqueue_style( 'shortcodes-ultimate' );
|
66 |
|
67 |
// Enqueue scripts
|
68 |
wp_enqueue_script( 'jquery' );
|
69 |
wp_enqueue_script( 'jwplayer' );
|
|
|
70 |
wp_enqueue_script( 'shortcodes-ultimate' );
|
71 |
}
|
72 |
|
@@ -105,6 +109,8 @@
|
|
105 |
add_shortcode( su_compatibility_mode_prefix() . 'column', 'su_column_shortcode' );
|
106 |
add_shortcode( su_compatibility_mode_prefix() . 'media', 'su_media_shortcode' );
|
107 |
add_shortcode( su_compatibility_mode_prefix() . 'table', 'su_table_shortcode' );
|
|
|
|
|
108 |
}
|
109 |
|
110 |
add_action( 'init', 'su_plugin_init' );
|
3 |
/*
|
4 |
Plugin Name: Shortcodes Ultimate
|
5 |
Plugin URI: http://ilovecode.ru/?p=122
|
6 |
+
Version: 1.7.0
|
7 |
Author: Vladimir Anokhin
|
8 |
Author URI: http://ilovecode.ru/
|
9 |
Description: Provides support for many easy to use shortcodes
|
48 |
// Register styles
|
49 |
wp_register_style( 'shortcodes-ultimate', su_plugin_url() . '/css/style.css', false, su_get_version(), 'all' );
|
50 |
wp_register_style( 'shortcodes-ultimate-admin', su_plugin_url() . '/css/admin.css', false, su_get_version(), 'all' );
|
51 |
+
wp_register_style( 'nivo-slider', su_plugin_url() . '/css/nivo-slider.css', false, su_get_version(), 'all' );
|
52 |
wp_register_style( 'codemirror', su_plugin_url() . '/css/codemirror.css', false, su_get_version(), 'all' );
|
53 |
wp_register_style( 'codemirror-css', su_plugin_url() . '/css/codemirror-css.css', false, su_get_version(), 'all' );
|
54 |
|
55 |
// Register scripts
|
56 |
wp_register_script( 'shortcodes-ultimate', su_plugin_url() . '/js/init.js', false, su_get_version(), false );
|
57 |
wp_register_script( 'shortcodes-ultimate-admin', su_plugin_url() . '/js/admin.js', false, su_get_version(), false );
|
58 |
+
wp_register_script( 'nivo-slider', su_plugin_url() . '/js/jquery.nivo.slider.pack.js', false, su_get_version(), false );
|
59 |
wp_register_script( 'codemirror', su_plugin_url() . '/js/codemirror.js', false, su_get_version(), false );
|
60 |
wp_register_script( 'codemirror-css', su_plugin_url() . '/js/codemirror-css.js', false, su_get_version(), false );
|
61 |
wp_register_script( 'jwplayer', su_plugin_url() . '/js/jwplayer.js', false, su_get_version(), false );
|
64 |
if ( !is_admin() ) {
|
65 |
|
66 |
// Enqueue styles
|
67 |
+
wp_enqueue_style( 'nivo-slider' );
|
68 |
wp_enqueue_style( 'shortcodes-ultimate' );
|
69 |
|
70 |
// Enqueue scripts
|
71 |
wp_enqueue_script( 'jquery' );
|
72 |
wp_enqueue_script( 'jwplayer' );
|
73 |
+
wp_enqueue_script( 'nivo-slider' );
|
74 |
wp_enqueue_script( 'shortcodes-ultimate' );
|
75 |
}
|
76 |
|
109 |
add_shortcode( su_compatibility_mode_prefix() . 'column', 'su_column_shortcode' );
|
110 |
add_shortcode( su_compatibility_mode_prefix() . 'media', 'su_media_shortcode' );
|
111 |
add_shortcode( su_compatibility_mode_prefix() . 'table', 'su_table_shortcode' );
|
112 |
+
add_shortcode( su_compatibility_mode_prefix() . 'photoshop', 'su_photoshop_shortcode' );
|
113 |
+
add_shortcode( su_compatibility_mode_prefix() . 'nivo_slider', 'su_nivo_slider_shortcode' );
|
114 |
}
|
115 |
|
116 |
add_action( 'init', 'su_plugin_init' );
|