WP Shortcode by MyThemeShop - Version 1.4.12

Version Description

  • Fixed responsive column issue.
Download this release

Release Info

Developer pratikmts
Plugin Icon 128x128 WP Shortcode by MyThemeShop
Version 1.4.12
Comparing to
See all releases

Code changes from version 1.4.10 to 1.4.12

css/wp-shortcode.css CHANGED
@@ -1,286 +1,293 @@
1
- /*-----------------------------------------------
2
- /* Plugin: WP Shortcode
3
- /* Author: MyThemeShop
4
- /* Version: 1.4
5
- /*---------------------------------------------*/
6
- /*-[ Notifications ]---------------------------*/
7
- .message_box {
8
- margin: 15px 0;
9
- padding: 1em 1em;
10
- }
11
- .message_box p { margin-bottom: 0 }
12
- pre {
13
- overflow: auto;
14
- padding: 15px;
15
- margin: 15px 0;
16
- position: relative;
17
- background: #777;
18
- font-family: monospace;
19
- color: #FFF;
20
- box-sizing: border-box;
21
- }
22
- .note {
23
- background: #FAF3D4;
24
- color: #A6A377;
25
- }
26
- .announce {
27
- background: #d0e6f0;
28
- color: #7190a2;
29
- }
30
- .success {
31
- border: 1px solid #DEF1BF;
32
- background: #D8EBCE;
33
- color: #748F5D;
34
- }
35
- .warning {
36
- border: 1px solid #FFDBDB;
37
- background: #FDE2E2;
38
- color: #AC888A;
39
- }
40
- /*-[ Buttons ]---------------------------------*/
41
- .buttons {
42
- font-size: 12px;
43
- text-decoration: none;
44
- border-radius: 5px;
45
- -webkit-border-radius: 5px;
46
- -moz-border-radius: 5px;
47
- margin: 0 15px 15px 0;
48
- padding: 12px 10px;
49
- overflow: hidden;
50
- display: inline-block;
51
- width: auto;
52
- }
53
- .buttons span {
54
- float: none;
55
- overflow: hidden;
56
- }
57
- a.buttons {
58
- color: #fff!important;
59
- text-decoration: none;
60
- padding: 10px 20px;
61
- border-radius: 3px;
62
- border: 1px solid rgba(0, 0, 0, 0.1);
63
- text-transform: uppercase;
64
- font-weight: bold;
65
- }
66
- a.buttons.left {
67
- margin-right: 15px;
68
- margin-bottom: 15px;
69
- float: left;
70
- }
71
- a.buttons.right {
72
- margin-left: 15px;
73
- margin-bottom: 15px;
74
- margin-right: 0;
75
- float: right;
76
- }
77
- div.button-center {
78
- width: 100%;
79
- text-align: center;
80
- }
81
- a.buttons.center {
82
- clear: both;
83
- display: inline-block;
84
- float: none;
85
- width: auto;
86
- }
87
- a.btn_white { color: #4F4F4F!important }
88
- .btn_brown {
89
- background-color: #C5703F;
90
- color: white;
91
- }
92
- .btn_brown:hover {
93
- background-color: #D1B593;
94
- color: white!important;
95
- }
96
- .btn_blue {
97
- background-color: #A5B8DA;
98
- color: white;
99
- }
100
- .btn_blue:hover {
101
- background-color: #9badcc;
102
- color: white!important;
103
- }
104
- .btn_green {
105
- background-color: #6CB24C;
106
- color: white;
107
- }
108
- .btn_green:hover {
109
- background-color: #5F9D43;
110
- color: white!important;
111
- }
112
- .btn_yellow {
113
- background-color: #FFDA6B;
114
- color: #fff;
115
- }
116
- .btn_yellow:hover {
117
- background-color: #FFD351;
118
- color: #fff!important;
119
- }
120
- .btn_red {
121
- background-color: #E83030;
122
- color: white;
123
- }
124
- .btn_red:hover {
125
- background-color: #E63131;
126
- color: white!important;
127
- }
128
- .btn_white {
129
- background-color: #F7F7F7;
130
- color: #4F4F4F;
131
- }
132
- .btn_white:hover {
133
- background-color: #F4F4F4;
134
- color: #4F4F4F!important;
135
- }
136
- .btn_white:active {
137
- border: 1px solid #C1C1C1;
138
- box-shadow: inset 0 0 8px 2px #C1C1C1;
139
- }
140
- /*-[ Video Shortcode ]-------------------------*/
141
- .textwidget .youtube-video, .textwidget .vimeo-video, .textwidget .googlemaps { margin: 0 }
142
- .youtube-video, .vimeo-video {
143
- margin: 10px 0 10px 0;
144
- width: 100%;
145
- }
146
- /*-[ Google Maps ]-----------------------------*/
147
- .googlemaps { margin: 5px 15px 10px 0 }
148
- /*-[ Columns ]---------------------------------*/
149
- .one_half { width: 48% }
150
- .one_third { width: 30.66% }
151
- .two_third { width: 65.33% }
152
- .one_fourth { width: 22% }
153
- .three_fourth { width: 74% }
154
- .one_fifth { width: 16.8% }
155
- .two_fifth { width: 37.6% }
156
- .three_fifth { width: 58.4% }
157
- .four_fifth { width: 67.2% }
158
- .one_sixth { width: 13.33% }
159
- .five_sixth { width: 82.67% }
160
- .one_half, .one_third, .two_third, .three_fourth, .one_fourth, .one_fifth, .two_fifth, .three_fifth, .four_fifth, .one_sixth, .five_sixth {
161
- position: relative;
162
- margin-right: 4%;
163
- margin-bottom: 15px;
164
- float: left;
165
- }
166
- .column-last {
167
- margin-right: 0!important;
168
- clear: right;
169
- }
170
- /*-[ Tabs ]------------------------------------*/
171
- .tab_widget {
172
- display: block;
173
- position: relative;
174
- margin: 0 0 20px 0;
175
- }
176
- .tab_widget ul.wps_tabs {
177
- display: block;
178
- position: relative;
179
- list-style: none;
180
- height: 40px;
181
- border-bottom: 1px solid #DDD;
182
- margin: 0;
183
- padding: 0;
184
- }
185
- .tab_widget ul.wps_tabs li {
186
- float: left;
187
- margin: 0;
188
- padding: 0;
189
- height: 39px;
190
- line-height: 39px;
191
- border: 1px solid #DDD;
192
- border-left: none;
193
- margin-bottom: -1px;
194
- overflow: hidden;
195
- position: relative;
196
- background-image: linear-gradient(bottom, rgb(230,230,230) 9%, rgb(238,238,238) 55%);
197
- background-image: -ms-linear-gradient(bottom, rgb(230,230,230) 9%, rgb(238,238,238) 55%);
198
- background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0.09, rgb(230,230,230)), color-stop(0.55, rgb(238,238,238)) );
199
- }
200
- .tab_widget ul.wps_tabs li:first-child { border-left: 1px solid #DDD }
201
- .tab_widget ul.wps_tabs li a {
202
- text-decoration: none;
203
- color: #888!important;
204
- font-size: 12px;
205
- display: block;
206
- padding: 0 10px;
207
- outline: none;
208
- font-weight: bold;
209
- text-shadow: 1px 1px 1px #FFF;
210
- border: none;
211
- border-left: 1px solid #F9F9F9;
212
- }
213
- .tab_widget ul.wps_tabs li:first-child a { border-left: none }
214
- .tab_widget ul.wps_tabs li a:hover { background: none }
215
- .tab_widget ul.wps_tabs li.active, .tab_widget ul.wps_tabs li.active a:hover {
216
- background: #FFF;
217
- border-bottom: 1px solid #FFF;
218
- }
219
- .tab_widget ul.wps_tabs li.active { border-top: 1px solid #DDD }
220
- .tab_widget ul.wps_tabs li.active a { color: #777 }
221
- .tab_widget .tab_container {
222
- display: block;
223
- border-top: none;
224
- overflow: hidden;
225
- position: relative;
226
- clear: both;
227
- background: #FFF;
228
- border: 1px solid #DDD;
229
- border-top: none;
230
- }
231
- .tab_widget .tab_content {
232
- display: block;
233
- position: relative;
234
- padding: 15px;
235
- }
236
- /*-[ Toggle ]-----------------------*/
237
- .toggle {
238
- display: block;
239
- position: relative;
240
- margin: 0 0 20px 0;
241
- }
242
- .toggle .wps_togglet, .toggle .toggleta {
243
- display: block;
244
- position: relative;
245
- min-height: 36px;
246
- padding: 0 12px;
247
- background: #EEE;
248
- border: 1px solid #DDD;
249
- cursor: pointer;
250
- margin: 0;
251
- }
252
- .toggle .wps_togglet span, .toggle .toggleta span {
253
- display: block;
254
- min-height: 36px;
255
- line-height: 36px;
256
- color: #888;
257
- text-shadow: 1px 1px 1px #FFF;
258
- padding-left: 20px;
259
- background: url("../images/toggle-down.png") no-repeat left;
260
- }
261
- .toggle .toggleta span { background: url("../images/toggle-up.png") no-repeat left }
262
- .toggle .togglec {
263
- display: block;
264
- position: relative;
265
- padding: 15px;
266
- background: #FFF;
267
- border: 1px solid #DDD;
268
- border-top: none;
269
- }
270
- /*-[ Dividers ]--------------------------------*/
271
- .divider {
272
- clear: both;
273
- display: block;
274
- padding-top: 20px;
275
- width: 100%;
276
- margin-bottom: 10px;
277
- text-align: right;
278
- padding-bottom: 5px;
279
- border-bottom: 5px solid #EEE;
280
- }
281
- .top-of-page {
282
- margin-bottom: 10px;
283
- text-align: right;
284
- padding-bottom: 5px;
285
- border-bottom: 5px solid #EEE;
286
- }
 
 
 
 
 
 
 
1
+ /*-----------------------------------------------
2
+ /* Plugin: WP Shortcode
3
+ /* Author: MyThemeShop
4
+ /* Version: 1.4
5
+ /*---------------------------------------------*/
6
+ /*-[ Notifications ]---------------------------*/
7
+ .message_box {
8
+ margin: 15px 0;
9
+ padding: 1em 1em;
10
+ }
11
+ .message_box p { margin-bottom: 0 }
12
+ pre {
13
+ overflow: auto;
14
+ padding: 15px;
15
+ margin: 15px 0;
16
+ position: relative;
17
+ background: #777;
18
+ font-family: monospace;
19
+ color: #FFF;
20
+ box-sizing: border-box;
21
+ }
22
+ .note {
23
+ background: #FAF3D4;
24
+ color: #A6A377;
25
+ }
26
+ .announce {
27
+ background: #d0e6f0;
28
+ color: #7190a2;
29
+ }
30
+ .success {
31
+ border: 1px solid #DEF1BF;
32
+ background: #D8EBCE;
33
+ color: #748F5D;
34
+ }
35
+ .warning {
36
+ border: 1px solid #FFDBDB;
37
+ background: #FDE2E2;
38
+ color: #AC888A;
39
+ }
40
+ /*-[ Buttons ]---------------------------------*/
41
+ .buttons {
42
+ font-size: 12px;
43
+ text-decoration: none;
44
+ border-radius: 5px;
45
+ -webkit-border-radius: 5px;
46
+ -moz-border-radius: 5px;
47
+ margin: 0 15px 15px 0;
48
+ padding: 12px 10px;
49
+ overflow: hidden;
50
+ display: inline-block;
51
+ width: auto;
52
+ }
53
+ .buttons span {
54
+ float: none;
55
+ overflow: hidden;
56
+ }
57
+ a.buttons {
58
+ color: #fff!important;
59
+ text-decoration: none;
60
+ padding: 10px 20px;
61
+ border-radius: 3px;
62
+ border: 1px solid rgba(0, 0, 0, 0.1);
63
+ text-transform: uppercase;
64
+ font-weight: bold;
65
+ }
66
+ a.buttons.left {
67
+ margin-right: 15px;
68
+ margin-bottom: 15px;
69
+ float: left;
70
+ }
71
+ a.buttons.right {
72
+ margin-left: 15px;
73
+ margin-bottom: 15px;
74
+ margin-right: 0;
75
+ float: right;
76
+ }
77
+ div.button-center {
78
+ width: 100%;
79
+ text-align: center;
80
+ }
81
+ a.buttons.center {
82
+ clear: both;
83
+ display: inline-block;
84
+ float: none;
85
+ width: auto;
86
+ }
87
+ a.btn_white { color: #4F4F4F!important }
88
+ .btn_brown {
89
+ background-color: #C5703F;
90
+ color: white;
91
+ }
92
+ .btn_brown:hover {
93
+ background-color: #D1B593;
94
+ color: white!important;
95
+ }
96
+ .btn_blue {
97
+ background-color: #A5B8DA;
98
+ color: white;
99
+ }
100
+ .btn_blue:hover {
101
+ background-color: #9badcc;
102
+ color: white!important;
103
+ }
104
+ .btn_green {
105
+ background-color: #6CB24C;
106
+ color: white;
107
+ }
108
+ .btn_green:hover {
109
+ background-color: #5F9D43;
110
+ color: white!important;
111
+ }
112
+ .btn_yellow {
113
+ background-color: #FFDA6B;
114
+ color: #fff;
115
+ }
116
+ .btn_yellow:hover {
117
+ background-color: #FFD351;
118
+ color: #fff!important;
119
+ }
120
+ .btn_red {
121
+ background-color: #E83030;
122
+ color: white;
123
+ }
124
+ .btn_red:hover {
125
+ background-color: #E63131;
126
+ color: white!important;
127
+ }
128
+ .btn_white {
129
+ background-color: #F7F7F7;
130
+ color: #4F4F4F;
131
+ }
132
+ .btn_white:hover {
133
+ background-color: #F4F4F4;
134
+ color: #4F4F4F!important;
135
+ }
136
+ .btn_white:active {
137
+ border: 1px solid #C1C1C1;
138
+ box-shadow: inset 0 0 8px 2px #C1C1C1;
139
+ }
140
+ /*-[ Video Shortcode ]-------------------------*/
141
+ .textwidget .youtube-video, .textwidget .vimeo-video, .textwidget .googlemaps { margin: 0 }
142
+ .youtube-video, .vimeo-video {
143
+ margin: 10px 0 10px 0;
144
+ width: 100%;
145
+ }
146
+ /*-[ Google Maps ]-----------------------------*/
147
+ .googlemaps { margin: 5px 15px 10px 0 }
148
+ /*-[ Columns ]---------------------------------*/
149
+ .one_half { width: 48% }
150
+ .one_third { width: 30.66% }
151
+ .two_third { width: 65.33% }
152
+ .one_fourth { width: 22% }
153
+ .three_fourth { width: 74% }
154
+ .one_fifth { width: 16.8% }
155
+ .two_fifth { width: 37.6% }
156
+ .three_fifth { width: 58.4% }
157
+ .four_fifth { width: 67.2% }
158
+ .one_sixth { width: 13.33% }
159
+ .five_sixth { width: 82.67% }
160
+ .one_half, .one_third, .two_third, .three_fourth, .one_fourth, .one_fifth, .two_fifth, .three_fifth, .four_fifth, .one_sixth, .five_sixth {
161
+ position: relative;
162
+ margin-right: 4%;
163
+ margin-bottom: 15px;
164
+ float: left;
165
+ }
166
+ .column-last {
167
+ margin-right: 0!important;
168
+ clear: right;
169
+ }
170
+ /*-[ Tabs ]------------------------------------*/
171
+ .tab_widget {
172
+ display: block;
173
+ position: relative;
174
+ margin: 0 0 20px 0;
175
+ }
176
+ .tab_widget ul.wps_tabs {
177
+ display: block;
178
+ position: relative;
179
+ list-style: none;
180
+ height: 40px;
181
+ border-bottom: 1px solid #DDD;
182
+ margin: 0;
183
+ padding: 0;
184
+ }
185
+ .tab_widget ul.wps_tabs li {
186
+ float: left;
187
+ margin: 0;
188
+ padding: 0;
189
+ height: 39px;
190
+ line-height: 39px;
191
+ border: 1px solid #DDD;
192
+ border-left: none;
193
+ margin-bottom: -1px;
194
+ overflow: hidden;
195
+ position: relative;
196
+ background-image: linear-gradient(bottom, rgb(230,230,230) 9%, rgb(238,238,238) 55%);
197
+ background-image: -ms-linear-gradient(bottom, rgb(230,230,230) 9%, rgb(238,238,238) 55%);
198
+ background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0.09, rgb(230,230,230)), color-stop(0.55, rgb(238,238,238)) );
199
+ }
200
+ .tab_widget ul.wps_tabs li:first-child { border-left: 1px solid #DDD }
201
+ .tab_widget ul.wps_tabs li a {
202
+ text-decoration: none;
203
+ color: #888!important;
204
+ font-size: 12px;
205
+ display: block;
206
+ padding: 0 10px;
207
+ outline: none;
208
+ font-weight: bold;
209
+ text-shadow: 1px 1px 1px #FFF;
210
+ border: none;
211
+ border-left: 1px solid #F9F9F9;
212
+ }
213
+ .tab_widget ul.wps_tabs li:first-child a { border-left: none }
214
+ .tab_widget ul.wps_tabs li a:hover { background: none }
215
+ .tab_widget ul.wps_tabs li.active, .tab_widget ul.wps_tabs li.active a:hover {
216
+ background: #FFF;
217
+ border-bottom: 1px solid #FFF;
218
+ }
219
+ .tab_widget ul.wps_tabs li.active { border-top: 1px solid #DDD }
220
+ .tab_widget ul.wps_tabs li.active a { color: #777 }
221
+ .tab_widget .tab_container {
222
+ display: block;
223
+ border-top: none;
224
+ overflow: hidden;
225
+ position: relative;
226
+ clear: both;
227
+ background: #FFF;
228
+ border: 1px solid #DDD;
229
+ border-top: none;
230
+ }
231
+ .tab_widget .tab_content {
232
+ display: block;
233
+ position: relative;
234
+ padding: 15px;
235
+ }
236
+ /*-[ Toggle ]-----------------------*/
237
+ .toggle {
238
+ display: block;
239
+ position: relative;
240
+ margin: 0 0 20px 0;
241
+ }
242
+ .toggle .wps_togglet, .toggle .toggleta {
243
+ display: block;
244
+ position: relative;
245
+ min-height: 36px;
246
+ padding: 0 12px;
247
+ background: #EEE;
248
+ border: 1px solid #DDD;
249
+ cursor: pointer;
250
+ margin: 0;
251
+ }
252
+ .toggle .wps_togglet span, .toggle .toggleta span {
253
+ display: block;
254
+ min-height: 36px;
255
+ line-height: 36px;
256
+ color: #888;
257
+ text-shadow: 1px 1px 1px #FFF;
258
+ padding-left: 20px;
259
+ background: url("../images/toggle-down.png") no-repeat left;
260
+ }
261
+ .toggle .toggleta span { background: url("../images/toggle-up.png") no-repeat left }
262
+ .toggle .togglec {
263
+ display: block;
264
+ position: relative;
265
+ padding: 15px;
266
+ background: #FFF;
267
+ border: 1px solid #DDD;
268
+ border-top: none;
269
+ }
270
+ /*-[ Dividers ]--------------------------------*/
271
+ .divider {
272
+ clear: both;
273
+ display: block;
274
+ padding-top: 20px;
275
+ width: 100%;
276
+ margin-bottom: 10px;
277
+ text-align: right;
278
+ padding-bottom: 5px;
279
+ border-bottom: 5px solid #EEE;
280
+ }
281
+ .top-of-page {
282
+ margin-bottom: 10px;
283
+ text-align: right;
284
+ padding-bottom: 5px;
285
+ border-bottom: 5px solid #EEE;
286
+ }
287
+
288
+ @media screen and (max-width: 480px) {
289
+ .one_half, .one_third, .two_third, .three_fourth, .one_fourth, .one_fifth, .two_fifth, .three_fifth, .four_fifth, .one_sixth, .five_sixth {
290
+ width: 100%;
291
+ margin-right: 0;
292
+ }
293
+ }
js/wp-shortcode.js CHANGED
@@ -1,38 +1,38 @@
1
- jQuery(document).ready(function($){
2
- // Toggles
3
- if ($('.wp_shortcodes_toggle').length) {
4
- $(".togglec").hide();
5
- $(".wps_togglet").click(function(){
6
- $(this).toggleClass("toggleta").next(".togglec").slideToggle("normal");
7
- });
8
- }
9
-
10
- // Tabs
11
- if ($('.wp_shortcodes_tabs').length) {
12
- $('.wp_shortcodes_tabs').each(function() {
13
- var $this = $(this);
14
- $this.find('.tab_content').slice(1).hide();
15
- $this.find('ul.wps_tabs li:first').addClass('active');
16
- $this.find('ul.wps_tabs li a').click(function(e) {
17
- e.preventDefault();
18
- var $this_a = $(this);
19
- var $tab = $this.find('#'+$this_a.data('tab'));
20
- if (! $tab.is(':visible')) {
21
- $this.find('.tab_content').hide();
22
- $this_a.parent().addClass('active').siblings().removeClass('active');
23
- $tab.fadeIn(600);
24
- }
25
- });
26
- });
27
- }
28
-
29
- if ($('.wp_shortcodes_tooltip').length) {
30
- $('.wp_shortcodes_tooltip').each(function(index, el) {
31
- var $this = $(this),
32
- ttgravity = $this.data('gravity'),
33
- ttfade = Boolean($this.data('fade'));
34
- $this.tipsy({gravity: ttgravity, fade: ttfade});
35
- });
36
- }
37
-
38
  });
1
+ jQuery(document).ready(function($){
2
+ // Toggles
3
+ if ($('.wp_shortcodes_toggle').length) {
4
+ $(".togglec").hide();
5
+ $(".wps_togglet").click(function(){
6
+ $(this).toggleClass("toggleta").next(".togglec").slideToggle("normal");
7
+ });
8
+ }
9
+
10
+ // Tabs
11
+ if ($('.wp_shortcodes_tabs').length) {
12
+ $('.wp_shortcodes_tabs').each(function() {
13
+ var $this = $(this);
14
+ $this.find('.tab_content').slice(1).hide();
15
+ $this.find('ul.wps_tabs li:first').addClass('active');
16
+ $this.find('ul.wps_tabs li a').click(function(e) {
17
+ e.preventDefault();
18
+ var $this_a = $(this);
19
+ var $tab = $this.find('#'+$this_a.data('tab'));
20
+ if (! $tab.is(':visible')) {
21
+ $this.find('.tab_content').hide();
22
+ $this_a.parent().addClass('active').siblings().removeClass('active');
23
+ $tab.fadeIn(600);
24
+ }
25
+ });
26
+ });
27
+ }
28
+
29
+ if ($('.wp_shortcodes_tooltip').length) {
30
+ $('.wp_shortcodes_tooltip').each(function(index, el) {
31
+ var $this = $(this),
32
+ ttgravity = $this.data('gravity'),
33
+ ttfade = Boolean($this.data('fade'));
34
+ $this.tipsy({gravity: ttgravity, fade: ttfade});
35
+ });
36
+ }
37
+
38
  });
readme.txt CHANGED
@@ -4,7 +4,7 @@ Creator's website link: http://mythemeshop.com/
4
  Tags: shortcodes, shortcode, shortcodes list, toggle shortcode, buttons, google map shortcode, youtube shortcode, vimeo shortcode, alert shortcode, notification shortcode, column shortcodes
5
  Requires at least: 3.0.1
6
  Tested up to: 4.9.4
7
- Stable tag: 1.4.10
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -65,6 +65,12 @@ Please disable all plugins and check if shortcode plugin is working properly. Th
65
 
66
  == Changelog ==
67
 
 
 
 
 
 
 
68
  = 1.4.10 =
69
  * Enqueued required scripts only on the pages where the plugin's shortcodes are used.
70
 
4
  Tags: shortcodes, shortcode, shortcodes list, toggle shortcode, buttons, google map shortcode, youtube shortcode, vimeo shortcode, alert shortcode, notification shortcode, column shortcodes
5
  Requires at least: 3.0.1
6
  Tested up to: 4.9.4
7
+ Stable tag: 1.4.12
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
65
 
66
  == Changelog ==
67
 
68
+ = 1.4.12 =
69
+ * Fixed responsive column issue.
70
+
71
+ = 1.4.11 =
72
+ * Fixed broken pages.
73
+
74
  = 1.4.10 =
75
  * Enqueued required scripts only on the pages where the plugin's shortcodes are used.
76
 
tinymce/editor_plugin.css CHANGED
@@ -1,8 +1,8 @@
1
- body#link { background: #fff; }
2
- #mnmshortcode_tag { width: 200px }
3
- #mnmshortcode_panel { margin-bottom: 8px }
4
- #mnmshortcode_panel table { width: 100%; font-size: 12px; }
5
- .mnmshortcode_description { color: #666; font-size: 12px; }
6
- .mnmshortcode_att_name { text-transform: capitalize }
7
- #mnmshortcode_panel input, #mnmshortcode_panel select, #mnmshortcode_panel textarea { width: 100%; padding: 4px 4px; font-size: 12px; font-family: 'Open Sans', sans-serif; }
8
  #mnmshortcode_panel textarea { height: 120px }
1
+ body#link { background: #fff; }
2
+ #mnmshortcode_tag { width: 200px }
3
+ #mnmshortcode_panel { margin-bottom: 8px }
4
+ #mnmshortcode_panel table { width: 100%; font-size: 12px; }
5
+ .mnmshortcode_description { color: #666; font-size: 12px; }
6
+ .mnmshortcode_att_name { text-transform: capitalize }
7
+ #mnmshortcode_panel input, #mnmshortcode_panel select, #mnmshortcode_panel textarea { width: 100%; padding: 4px 4px; font-size: 12px; font-family: 'Open Sans', sans-serif; }
8
  #mnmshortcode_panel textarea { height: 120px }
tinymce/editor_plugin.js CHANGED
@@ -1,80 +1,80 @@
1
- (function() {
2
- // Load plugin specific language pack
3
- tinymce.PluginManager.requireLangPack('wpspanel');
4
- tinymce.create('tinymce.plugins.wpspanel', {
5
- /**
6
- * Initializes the plugin, this will be executed after the plugin has been created.
7
- * This call is done before the editor instance has finished it's initialization so use the onInit event
8
- * of the editor instance to intercept that event.
9
- *
10
- * @param {tinymce.Editor} ed Editor instance that the plugin is initialized in.
11
- * @param {string} url Absolute URL to where the plugin is located.
12
- */
13
- init : function(ed, url) {
14
- // Register the command so that it can be invoked by using tinyMCE.activeEditor.execCommand('mceExample');
15
- ed.addCommand('mcewpspanel', function() {
16
- ed.windowManager.open({
17
- file : url + '/editor_plugin.php',
18
- inline : 1,
19
- width : 450 + ed.getLang('wpspanel.delta_width', 0),
20
- height : 80 + ed.getLang('wpspanel.delta_height', 0)
21
- }, {
22
- plugin_url : url, // Plugin absolute URL
23
- some_custom_arg : 'custom arg' // Custom argument
24
- });
25
- });
26
- // Resize function
27
- ed.addCommand( 'mcewpspanel_resize', function( ui, v ) {
28
- if (ed.windowManager.params === undefined) {
29
- // TinyMCE 4
30
- var windowID = ed.windowManager.windows[0]._id;
31
- var elem = window.top.document.getElementById(windowID+'-body');
32
- jQuery(elem).height(v.height + 52);
33
- } else {
34
- // TinyMCE 3
35
- ed.windowManager.params.mce_height = v.height + 52;
36
- }
37
-
38
- } );
39
- // Register example button
40
- ed.addButton('wpspanel', {
41
- title : 'Add Custom Shortcode',
42
- cmd : 'mcewpspanel',
43
- image : url + '/shortcode.png'
44
- });
45
-
46
- // Add a node change handler, selects the button in the UI when a image is selected
47
- ed.onNodeChange.add(function(ed, cm, n) {
48
- cm.setActive('wpspanel', n.nodeName == 'IMG');
49
- });
50
-
51
- },
52
-
53
- /**
54
- * Creates control instances based in the incomming name. This method is normally not
55
- * needed since the addButton method of the tinymce.Editor class is a more easy way of adding buttons
56
- * but you sometimes need to create more complex controls like listboxes, split buttons etc then this
57
- * method can be used to create those.
58
- *
59
- * @param {String} n Name of the control to create.
60
- * @param {tinymce.ControlManager} cm Control manager to use inorder to create new control.
61
- * @return {tinymce.ui.Control} New control instance or null if no control was created.
62
- */
63
- createControl : function(n, cm) {
64
- return null;
65
- },
66
-
67
- getInfo : function() {
68
- return {
69
- longname : 'WP Shortcode',
70
- author : 'MyThemeShop',
71
- authorurl : 'http://mythemeshop.com',
72
- infourl : 'http://mythemeshop.com/plugins/wp-shortcode',
73
- version : '1.4.2'
74
- };
75
- }
76
- });
77
-
78
- // Register plugin
79
- tinymce.PluginManager.add('wpspanel', tinymce.plugins.wpspanel);
80
  })();
1
+ (function() {
2
+ // Load plugin specific language pack
3
+ tinymce.PluginManager.requireLangPack('wpspanel');
4
+ tinymce.create('tinymce.plugins.wpspanel', {
5
+ /**
6
+ * Initializes the plugin, this will be executed after the plugin has been created.
7
+ * This call is done before the editor instance has finished it's initialization so use the onInit event
8
+ * of the editor instance to intercept that event.
9
+ *
10
+ * @param {tinymce.Editor} ed Editor instance that the plugin is initialized in.
11
+ * @param {string} url Absolute URL to where the plugin is located.
12
+ */
13
+ init : function(ed, url) {
14
+ // Register the command so that it can be invoked by using tinyMCE.activeEditor.execCommand('mceExample');
15
+ ed.addCommand('mcewpspanel', function() {
16
+ ed.windowManager.open({
17
+ file : url + '/editor_plugin.php',
18
+ inline : 1,
19
+ width : 450 + ed.getLang('wpspanel.delta_width', 0),
20
+ height : 80 + ed.getLang('wpspanel.delta_height', 0)
21
+ }, {
22
+ plugin_url : url, // Plugin absolute URL
23
+ some_custom_arg : 'custom arg' // Custom argument
24
+ });
25
+ });
26
+ // Resize function
27
+ ed.addCommand( 'mcewpspanel_resize', function( ui, v ) {
28
+ if (ed.windowManager.params === undefined) {
29
+ // TinyMCE 4
30
+ var windowID = ed.windowManager.windows[0]._id;
31
+ var elem = window.top.document.getElementById(windowID+'-body');
32
+ jQuery(elem).height(v.height + 52);
33
+ } else {
34
+ // TinyMCE 3
35
+ ed.windowManager.params.mce_height = v.height + 52;
36
+ }
37
+
38
+ } );
39
+ // Register example button
40
+ ed.addButton('wpspanel', {
41
+ title : 'Add Custom Shortcode',
42
+ cmd : 'mcewpspanel',
43
+ image : url + '/shortcode.png'
44
+ });
45
+
46
+ // Add a node change handler, selects the button in the UI when a image is selected
47
+ ed.onNodeChange.add(function(ed, cm, n) {
48
+ cm.setActive('wpspanel', n.nodeName == 'IMG');
49
+ });
50
+
51
+ },
52
+
53
+ /**
54
+ * Creates control instances based in the incomming name. This method is normally not
55
+ * needed since the addButton method of the tinymce.Editor class is a more easy way of adding buttons
56
+ * but you sometimes need to create more complex controls like listboxes, split buttons etc then this
57
+ * method can be used to create those.
58
+ *
59
+ * @param {String} n Name of the control to create.
60
+ * @param {tinymce.ControlManager} cm Control manager to use inorder to create new control.
61
+ * @return {tinymce.ui.Control} New control instance or null if no control was created.
62
+ */
63
+ createControl : function(n, cm) {
64
+ return null;
65
+ },
66
+
67
+ getInfo : function() {
68
+ return {
69
+ longname : 'WP Shortcode',
70
+ author : 'MyThemeShop',
71
+ authorurl : 'http://mythemeshop.com',
72
+ infourl : 'http://mythemeshop.com/plugins/wp-shortcode',
73
+ version : '1.4.2'
74
+ };
75
+ }
76
+ });
77
+
78
+ // Register plugin
79
+ tinymce.PluginManager.add('wpspanel', tinymce.plugins.wpspanel);
80
  })();
tinymce/editor_plugin.php CHANGED
@@ -1,66 +1,66 @@
1
- <?php
2
- // look up for the path
3
- require_once('mnm_config.php');
4
- // check for rights
5
- if ( !current_user_can('edit_pages') && !current_user_can('edit_posts') )
6
- wp_die(__("You are not allowed to be here", "wp-shortcode"));
7
- global $wpdb;
8
- ?>
9
- <html xmlns="http://www.w3.org/1999/xhtml">
10
- <head>
11
- <title><?php _e('Shortcode Panel', 'wp-shortcode'); ?></title>
12
- <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php echo get_option('blog_charset'); ?>" />
13
- <script language="javascript" type="text/javascript" src="<?php echo get_option('siteurl') ?>/wp-includes/js/tinymce/tiny_mce_popup.js"></script>
14
- <script language="javascript" type="text/javascript" src="<?php echo get_option('siteurl') ?>/wp-includes/js/tinymce/utils/mctabs.js"></script>
15
- <script language="javascript" type="text/javascript" src="<?php echo get_option('siteurl') ?>/wp-includes/js/tinymce/utils/form_utils.js"></script>
16
-
17
- <script language="javascript" type="text/javascript" src="<?php echo includes_url(); ?>js/jquery/jquery.js"></script>
18
- <?php include('shortcodes.php'); ?>
19
- <script language="javascript" type="text/javascript" src="<?php echo plugin_dir_url(__FILE__); ?>tinymce.js"></script>
20
- <base target="_self" />
21
- <link rel="stylesheet" type="text/css" href="<?php echo plugin_dir_url(__FILE__); ?>editor_plugin.css" media="all" />
22
- </head>
23
- <body id="link">
24
- <!-- <form onsubmit="insertLink();return false;" action="#"> -->
25
- <form name="mnm_tabs" action="#" id="mnmshortcode_form">
26
- <div>
27
- <!-- gallery panel -->
28
- <div id="mnmshortcode_panel" class="panel">
29
- <table border="0" cellpadding="4" cellspacing="0">
30
- <tr>
31
- <td><label for="mnmshortcode_tag"><?php _e("Select Shortcode", 'wp-shortcode'); ?></label></td>
32
- <td><select id="mnmshortcode_tag" name="mnmshortcode_tag">
33
- <option value="0"><?php _e('Select Shortcode', 'wp-shortcode'); ?></option>
34
- <?php
35
- if(is_array($shortcodes)) {
36
- $i = 1;
37
-
38
- foreach ( $shortcodes as $mnm_shortcodekey => $short_code_value ) {
39
- echo '<option value="' . $mnm_shortcodekey . '" >' . (isset($short_code_value['label']) ? $short_code_value['label'] : $mnm_shortcodekey).'</option>' . "\n";
40
- $i++;
41
- }
42
- }
43
- ?>
44
- </select></td>
45
- </tr>
46
-
47
- </table>
48
- </div>
49
-
50
- </div>
51
-
52
-
53
- </div>
54
-
55
- <div class="mceActionPanel">
56
- <div style="float: left">
57
- <input type="button" id="cancel" name="cancel" value="<?php _e('Cancel', 'wp-shortcode'); ?>" onClick="tinyMCEPopup.close();" />
58
- </div>
59
-
60
- <div style="float: right">
61
- <input type="submit" id="insert" name="insert" value="<?php _e('Insert', 'wp-shortcode'); ?>" onClick="mnmshortcodesubmit();" />
62
- </div>
63
- </div>
64
- </form>
65
- </body>
66
  </html>
1
+ <?php
2
+ // look up for the path
3
+ require_once('mnm_config.php');
4
+ // check for rights
5
+ if ( !current_user_can('edit_pages') && !current_user_can('edit_posts') )
6
+ wp_die(__("You are not allowed to be here", "wp-shortcode"));
7
+ global $wpdb;
8
+ ?>
9
+ <html xmlns="http://www.w3.org/1999/xhtml">
10
+ <head>
11
+ <title><?php _e('Shortcode Panel', 'wp-shortcode'); ?></title>
12
+ <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php echo get_option('blog_charset'); ?>" />
13
+ <script language="javascript" type="text/javascript" src="<?php echo get_option('siteurl') ?>/wp-includes/js/tinymce/tiny_mce_popup.js"></script>
14
+ <script language="javascript" type="text/javascript" src="<?php echo get_option('siteurl') ?>/wp-includes/js/tinymce/utils/mctabs.js"></script>
15
+ <script language="javascript" type="text/javascript" src="<?php echo get_option('siteurl') ?>/wp-includes/js/tinymce/utils/form_utils.js"></script>
16
+
17
+ <script language="javascript" type="text/javascript" src="<?php echo includes_url(); ?>js/jquery/jquery.js"></script>
18
+ <?php include('shortcodes.php'); ?>
19
+ <script language="javascript" type="text/javascript" src="<?php echo plugin_dir_url(__FILE__); ?>tinymce.js"></script>
20
+ <base target="_self" />
21
+ <link rel="stylesheet" type="text/css" href="<?php echo plugin_dir_url(__FILE__); ?>editor_plugin.css" media="all" />
22
+ </head>
23
+ <body id="link">
24
+ <!-- <form onsubmit="insertLink();return false;" action="#"> -->
25
+ <form name="mnm_tabs" action="#" id="mnmshortcode_form">
26
+ <div>
27
+ <!-- gallery panel -->
28
+ <div id="mnmshortcode_panel" class="panel">
29
+ <table border="0" cellpadding="4" cellspacing="0">
30
+ <tr>
31
+ <td><label for="mnmshortcode_tag"><?php _e("Select Shortcode", 'wp-shortcode'); ?></label></td>
32
+ <td><select id="mnmshortcode_tag" name="mnmshortcode_tag">
33
+ <option value="0"><?php _e('Select Shortcode', 'wp-shortcode'); ?></option>
34
+ <?php
35
+ if(is_array($shortcodes)) {
36
+ $i = 1;
37
+
38
+ foreach ( $shortcodes as $mnm_shortcodekey => $short_code_value ) {
39
+ echo '<option value="' . $mnm_shortcodekey . '" >' . (isset($short_code_value['label']) ? $short_code_value['label'] : $mnm_shortcodekey).'</option>' . "\n";
40
+ $i++;
41
+ }
42
+ }
43
+ ?>
44
+ </select></td>
45
+ </tr>
46
+
47
+ </table>
48
+ </div>
49
+
50
+ </div>
51
+
52
+
53
+ </div>
54
+
55
+ <div class="mceActionPanel">
56
+ <div style="float: left">
57
+ <input type="button" id="cancel" name="cancel" value="<?php _e('Cancel', 'wp-shortcode'); ?>" onClick="tinyMCEPopup.close();" />
58
+ </div>
59
+
60
+ <div style="float: right">
61
+ <input type="submit" id="insert" name="insert" value="<?php _e('Insert', 'wp-shortcode'); ?>" onClick="mnmshortcodesubmit();" />
62
+ </div>
63
+ </div>
64
+ </form>
65
+ </body>
66
  </html>
tinymce/langs.php CHANGED
@@ -1,6 +1,6 @@
1
- <script type="text/javascript">
2
- tinyMCE.addI18n({en:{
3
- systempanel:{
4
- desc : 'System shortcodes'
5
- }}});
6
  </script>
1
+ <script type="text/javascript">
2
+ tinyMCE.addI18n({en:{
3
+ systempanel:{
4
+ desc : 'System shortcodes'
5
+ }}});
6
  </script>
tinymce/mnm_config.php CHANGED
@@ -1,9 +1,9 @@
1
- <?php
2
- $wp_include = "../wp-load.php";
3
- $i = 0;
4
- while (!file_exists($wp_include) && $i++ < 10) {
5
- $wp_include = "../$wp_include";
6
- }
7
-
8
- // load WordPress
9
  require($wp_include);
1
+ <?php
2
+ $wp_include = "../wp-load.php";
3
+ $i = 0;
4
+ while (!file_exists($wp_include) && $i++ < 10) {
5
+ $wp_include = "../$wp_include";
6
+ }
7
+
8
+ // load WordPress
9
  require($wp_include);
tinymce/tinymce.js CHANGED
@@ -1,93 +1,93 @@
1
- function mnmshortcodesubmit() {
2
- var tagtext;
3
- var mnm_shortcodeid = document.getElementById('mnmshortcode_tag').value;
4
- if (mnm_shortcodeid == 0) {
5
- tinyMCEPopup.close();
6
- return;
7
- }
8
- if (typeof shortcodes[mnm_shortcodeid] != 'undefined') {
9
- tagtext = "["+mnm_shortcodeid + ' ';
10
- jQuery.each(shortcodes[mnm_shortcodeid]['atts'], function(index, item) {
11
- tagtext += index + '="' + jQuery('#shortcode_att_'+index).val() + '" ';
12
- });
13
-
14
- tagtext = tagtext.trim() + "]";
15
- if (!shortcodes[mnm_shortcodeid]['self-closing']) {
16
- tagtext += jQuery('#shortcode_content').val() + "[/" + mnm_shortcodeid + "]";
17
- }
18
- } else {
19
- tagtext="["+mnm_shortcodeid + "]Insert your content here[/" + mnm_shortcodeid + "]";
20
- }
21
-
22
- if(window.tinyMCE) {
23
- if (window.tinyMCE.execInstanceCommand === undefined) {
24
- // tinyMCE 4
25
- tinyMCEPopup.editor.insertContent(tagtext);
26
- } else {
27
- // tinyMCE 3
28
- window.tinyMCE.execInstanceCommand('content', 'mceInsertContent', false, tagtext);
29
- }
30
- tinyMCEPopup.editor.execCommand('mceRepaint');
31
- tinyMCEPopup.close();
32
- }
33
- return;
34
- }
35
-
36
- // document ready
37
- jQuery(function($) {
38
- $('#mnmshortcode_panel').append('<table id="mnmshortcode_atts" border="0" cellpadding="4" cellspacing="0"></table>');
39
- tinyMCEPopup.resizeToInnerSize();
40
- $('#mnmshortcode_tag').change(function() {
41
- var mnm_shortcodeid = $(this).val();
42
- var $atts_table = $('#mnmshortcode_atts');
43
- $atts_table.empty();
44
- // build form
45
- if (typeof shortcodes[mnm_shortcodeid] != 'undefined') {
46
- var html = '';
47
-
48
- if (shortcodes[mnm_shortcodeid]['description']) {
49
- html += '<tr><td class="mnmshortcode_description" colspan="2">'+shortcodes[mnm_shortcodeid]['description']+'</td></tr>';
50
- }
51
- $.each(shortcodes[mnm_shortcodeid]['atts'], function(index, item) {
52
- html += '<tr class="mnmshortcode_att_name"><td>'+index+'</td><td><input type="text" name="shortcode_att_'+index+'" id="shortcode_att_'+index+'" value="'+item+'" /></td></tr>';
53
- });
54
-
55
- if (!shortcodes[mnm_shortcodeid]['self-closing']) {
56
- if (shortcodes[mnm_shortcodeid]['content_field'] == undefined) {
57
- shortcodes[mnm_shortcodeid]['content_field'] = 'input';
58
- }
59
- switch (shortcodes[mnm_shortcodeid]['content_field']) {
60
- case 'input':
61
- html += '<tr class="mnmshortcode_content"><td>Content</td><td><input type="text" name="shortcode_content" id="shortcode_content" value="'+shortcodes[mnm_shortcodeid]['content']+'" /></td></tr>';
62
- break;
63
-
64
- case 'textarea':
65
- html += '<tr class="mnmshortcode_content"><td>Content</td><td><textarea name="shortcode_content" id="shortcode_content">'+shortcodes[mnm_shortcodeid]['content']+'</textarea></td></tr>';
66
- break;
67
-
68
- default:
69
- html += '<tr class="mnmshortcode_content"><td>Content</td><td><input type="text" name="shortcode_content" id="shortcode_content" value="'+shortcodes[mnm_shortcodeid]['content']+'" /></td></tr>';
70
- break;
71
- }
72
-
73
- }
74
- $atts_table.append(html);
75
- $('.mnmshortcode_att_name input, .mnmshortcode_content input').each(function() {
76
- var $this = $(this);
77
- $this.data('defaultVal', $this.val())
78
- .css('color', '#777777')
79
- .focus(function() {
80
- if ($this.val() == $this.data('defaultVal')) {
81
- $this.val('').css('color', '#000000');
82
- }
83
- });
84
- });
85
- }
86
- tinyMCEPopup.execCommand( 'mcewpspanel_resize', false, { height : $('#mnmshortcode_form').height() } );
87
- tinyMCEPopup.resizeToInnerSize();
88
- });
89
-
90
- // Resize onLoad
91
- tinyMCEPopup.execCommand( 'mcewpspanel_resize', false, { height : 50 } );
92
- tinyMCEPopup.resizeToInnerSize();
93
  });
1
+ function mnmshortcodesubmit() {
2
+ var tagtext;
3
+ var mnm_shortcodeid = document.getElementById('mnmshortcode_tag').value;
4
+ if (mnm_shortcodeid == 0) {
5
+ tinyMCEPopup.close();
6
+ return;
7
+ }
8
+ if (typeof shortcodes[mnm_shortcodeid] != 'undefined') {
9
+ tagtext = "["+mnm_shortcodeid + ' ';
10
+ jQuery.each(shortcodes[mnm_shortcodeid]['atts'], function(index, item) {
11
+ tagtext += index + '="' + jQuery('#shortcode_att_'+index).val() + '" ';
12
+ });
13
+
14
+ tagtext = tagtext.trim() + "]";
15
+ if (!shortcodes[mnm_shortcodeid]['self-closing']) {
16
+ tagtext += jQuery('#shortcode_content').val() + "[/" + mnm_shortcodeid + "]";
17
+ }
18
+ } else {
19
+ tagtext="["+mnm_shortcodeid + "]Insert your content here[/" + mnm_shortcodeid + "]";
20
+ }
21
+
22
+ if(window.tinyMCE) {
23
+ if (window.tinyMCE.execInstanceCommand === undefined) {
24
+ // tinyMCE 4
25
+ tinyMCEPopup.editor.insertContent(tagtext);
26
+ } else {
27
+ // tinyMCE 3
28
+ window.tinyMCE.execInstanceCommand('content', 'mceInsertContent', false, tagtext);
29
+ }
30
+ tinyMCEPopup.editor.execCommand('mceRepaint');
31
+ tinyMCEPopup.close();
32
+ }
33
+ return;
34
+ }
35
+
36
+ // document ready
37
+ jQuery(function($) {
38
+ $('#mnmshortcode_panel').append('<table id="mnmshortcode_atts" border="0" cellpadding="4" cellspacing="0"></table>');
39
+ tinyMCEPopup.resizeToInnerSize();
40
+ $('#mnmshortcode_tag').change(function() {
41
+ var mnm_shortcodeid = $(this).val();
42
+ var $atts_table = $('#mnmshortcode_atts');
43
+ $atts_table.empty();
44
+ // build form
45
+ if (typeof shortcodes[mnm_shortcodeid] != 'undefined') {
46
+ var html = '';
47
+
48
+ if (shortcodes[mnm_shortcodeid]['description']) {
49
+ html += '<tr><td class="mnmshortcode_description" colspan="2">'+shortcodes[mnm_shortcodeid]['description']+'</td></tr>';
50
+ }
51
+ $.each(shortcodes[mnm_shortcodeid]['atts'], function(index, item) {
52
+ html += '<tr class="mnmshortcode_att_name"><td>'+index+'</td><td><input type="text" name="shortcode_att_'+index+'" id="shortcode_att_'+index+'" value="'+item+'" /></td></tr>';
53
+ });
54
+
55
+ if (!shortcodes[mnm_shortcodeid]['self-closing']) {
56
+ if (shortcodes[mnm_shortcodeid]['content_field'] == undefined) {
57
+ shortcodes[mnm_shortcodeid]['content_field'] = 'input';
58
+ }
59
+ switch (shortcodes[mnm_shortcodeid]['content_field']) {
60
+ case 'input':
61
+ html += '<tr class="mnmshortcode_content"><td>Content</td><td><input type="text" name="shortcode_content" id="shortcode_content" value="'+shortcodes[mnm_shortcodeid]['content']+'" /></td></tr>';
62
+ break;
63
+
64
+ case 'textarea':
65
+ html += '<tr class="mnmshortcode_content"><td>Content</td><td><textarea name="shortcode_content" id="shortcode_content">'+shortcodes[mnm_shortcodeid]['content']+'</textarea></td></tr>';
66
+ break;
67
+
68
+ default:
69
+ html += '<tr class="mnmshortcode_content"><td>Content</td><td><input type="text" name="shortcode_content" id="shortcode_content" value="'+shortcodes[mnm_shortcodeid]['content']+'" /></td></tr>';
70
+ break;
71
+ }
72
+
73
+ }
74
+ $atts_table.append(html);
75
+ $('.mnmshortcode_att_name input, .mnmshortcode_content input').each(function() {
76
+ var $this = $(this);
77
+ $this.data('defaultVal', $this.val())
78
+ .css('color', '#777777')
79
+ .focus(function() {
80
+ if ($this.val() == $this.data('defaultVal')) {
81
+ $this.val('').css('color', '#000000');
82
+ }
83
+ });
84
+ });
85
+ }
86
+ tinyMCEPopup.execCommand( 'mcewpspanel_resize', false, { height : $('#mnmshortcode_form').height() } );
87
+ tinyMCEPopup.resizeToInnerSize();
88
+ });
89
+
90
+ // Resize onLoad
91
+ tinyMCEPopup.execCommand( 'mcewpspanel_resize', false, { height : 50 } );
92
+ tinyMCEPopup.resizeToInnerSize();
93
  });
tinymce/tinymce.php CHANGED
@@ -1,76 +1,76 @@
1
- <?php
2
- class add_wpshortcodes_button {
3
- var $pluginname = 'wpspanel';
4
- var $path = '';
5
- var $internalVersion = 100;
6
-
7
- function __construct()
8
- {
9
-
10
- // Set path to editor_plugin.js
11
- $this->path = plugin_dir_url(__FILE__);
12
-
13
- // Modify the version when tinyMCE plugins are changed.
14
- add_filter('tiny_mce_version', array (&$this, 'change_tinymce_version') );
15
-
16
- // init process for button control
17
- add_action('init', array (&$this, 'addbuttons') );
18
- }
19
-
20
- function addbuttons()
21
- {
22
- global $page_handle;
23
-
24
- if ( !current_user_can('edit_posts') && !current_user_can('edit_pages') )
25
- return;
26
-
27
- // Add only in Rich Editor mode
28
- if ( get_user_option('rich_editing') == 'true')
29
- {
30
- add_filter("mce_external_plugins", array (&$this, 'add_tinymce_plugin' ), 5);
31
- add_filter('mce_buttons', array (&$this, 'register_button' ), 5);
32
- add_filter('mce_external_languages', array (&$this, 'add_tinymce_langs_path'));
33
- }
34
- }
35
-
36
- function register_button($buttons)
37
- {
38
- array_push($buttons, 'separator', $this->pluginname );
39
- return $buttons;
40
- }
41
-
42
- function add_tinymce_plugin($plugin_array)
43
- {
44
- $plugin_array[$this->pluginname] = $this->path . 'editor_plugin.js';
45
-
46
- return $plugin_array;
47
- }
48
-
49
- function add_tinymce_langs_path($plugin_array)
50
- {
51
- // Load the TinyMCE language file
52
- $plugin_array[$this->pluginname] = plugin_dir_url('tinymce/langs.php');
53
- return $plugin_array;
54
- }
55
-
56
-
57
- /**
58
- * add_nextgen_button::change_tinymce_version()
59
- * A different version will rebuild the cache
60
- *
61
- * @return $versio
62
- */
63
- function change_tinymce_version($version)
64
- {
65
- $version = $version + $this->internalVersion;
66
- return $version;
67
- }
68
-
69
- }
70
-
71
- // Call it after theme setup
72
- function mts_wpshortcodes_tinymce() {
73
- $tinymce_button = new add_wpshortcodes_button();
74
- }
75
- add_action( 'after_setup_theme', 'mts_wpshortcodes_tinymce' );
76
- ?>
1
+ <?php
2
+ class add_wpshortcodes_button {
3
+ var $pluginname = 'wpspanel';
4
+ var $path = '';
5
+ var $internalVersion = 100;
6
+
7
+ function __construct()
8
+ {
9
+
10
+ // Set path to editor_plugin.js
11
+ $this->path = plugin_dir_url(__FILE__);
12
+
13
+ // Modify the version when tinyMCE plugins are changed.
14
+ add_filter('tiny_mce_version', array (&$this, 'change_tinymce_version') );
15
+
16
+ // init process for button control
17
+ add_action('init', array (&$this, 'addbuttons') );
18
+ }
19
+
20
+ function addbuttons()
21
+ {
22
+ global $page_handle;
23
+
24
+ if ( !current_user_can('edit_posts') && !current_user_can('edit_pages') )
25
+ return;
26
+
27
+ // Add only in Rich Editor mode
28
+ if ( get_user_option('rich_editing') == 'true')
29
+ {
30
+ add_filter("mce_external_plugins", array (&$this, 'add_tinymce_plugin' ), 5);
31
+ add_filter('mce_buttons', array (&$this, 'register_button' ), 5);
32
+ add_filter('mce_external_languages', array (&$this, 'add_tinymce_langs_path'));
33
+ }
34
+ }
35
+
36
+ function register_button($buttons)
37
+ {
38
+ array_push($buttons, 'separator', $this->pluginname );
39
+ return $buttons;
40
+ }
41
+
42
+ function add_tinymce_plugin($plugin_array)
43
+ {
44
+ $plugin_array[$this->pluginname] = $this->path . 'editor_plugin.js';
45
+
46
+ return $plugin_array;
47
+ }
48
+
49
+ function add_tinymce_langs_path($plugin_array)
50
+ {
51
+ // Load the TinyMCE language file
52
+ $plugin_array[$this->pluginname] = plugin_dir_url('tinymce/langs.php');
53
+ return $plugin_array;
54
+ }
55
+
56
+
57
+ /**
58
+ * add_nextgen_button::change_tinymce_version()
59
+ * A different version will rebuild the cache
60
+ *
61
+ * @return $versio
62
+ */
63
+ function change_tinymce_version($version)
64
+ {
65
+ $version = $version + $this->internalVersion;
66
+ return $version;
67
+ }
68
+
69
+ }
70
+
71
+ // Call it after theme setup
72
+ function mts_wpshortcodes_tinymce() {
73
+ $tinymce_button = new add_wpshortcodes_button();
74
+ }
75
+ add_action( 'after_setup_theme', 'mts_wpshortcodes_tinymce' );
76
+ ?>
wp-shortcode.php CHANGED
@@ -4,7 +4,7 @@ Plugin Name: WP Shortcode by MyThemeShop
4
  Plugin URI: http://mythemeshop.com/
5
  Description: With the vast array of shortcodes, you can quickly and easily build content for your posts and pages and turbocharge your blogging experience.
6
  Author: MyThemeShop
7
- Version: 1.4.10
8
  Author URI: http://mythemeshop.com/
9
  */
10
 
4
  Plugin URI: http://mythemeshop.com/
5
  Description: With the vast array of shortcodes, you can quickly and easily build content for your posts and pages and turbocharge your blogging experience.
6
  Author: MyThemeShop
7
+ Version: 1.4.12
8
  Author URI: http://mythemeshop.com/
9
  */
10