Ditty News Ticker - Version 1.0.5

Version Description

  • Updated metaboxer scripts.
  • Updated direct function output.
  • Updated ticker types link.
  • Fixed rotator numbers padding.
  • Fixed limited number of DNT in widget drop down issue.
Download this release

Release Info

Developer metaphorcreations
Plugin Icon 128x128 Ditty News Ticker
Version 1.0.5
Comparing to
See all releases

Code changes from version 1.0.4 to 1.0.5

ditty-news-ticker.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Ditty News Ticker
4
  Plugin URI: http://dittynewsticker.com/
5
  Description: Ditty News Ticker is a multi-functional data display plugin
6
- Version: 1.0.4
7
  Author: Metaphor Creations
8
  Author URI: http://www.metaphorcreations.com
9
  License: GPL2
@@ -45,9 +45,9 @@ The icons are licensed under a Creative Commons Attribution
45
  * @since 1.0.0
46
  */
47
  if ( WP_DEBUG ) {
48
- define ( 'MTPHR_DNT_VERSION', '1.0.4-'.time() );
49
  } else {
50
- define ( 'MTPHR_DNT_VERSION', '1.0.4' );
51
  }
52
  define ( 'MTPHR_DNT_DIR', plugin_dir_path(__FILE__) );
53
  define ( 'MTPHR_DNT_URL', plugins_url().'/ditty-news-ticker' );
3
  Plugin Name: Ditty News Ticker
4
  Plugin URI: http://dittynewsticker.com/
5
  Description: Ditty News Ticker is a multi-functional data display plugin
6
+ Version: 1.0.5
7
  Author: Metaphor Creations
8
  Author URI: http://www.metaphorcreations.com
9
  License: GPL2
45
  * @since 1.0.0
46
  */
47
  if ( WP_DEBUG ) {
48
+ define ( 'MTPHR_DNT_VERSION', '1.0.5-'.time() );
49
  } else {
50
+ define ( 'MTPHR_DNT_VERSION', '1.0.5' );
51
  }
52
  define ( 'MTPHR_DNT_DIR', plugin_dir_path(__FILE__) );
53
  define ( 'MTPHR_DNT_URL', plugins_url().'/ditty-news-ticker' );
includes/edit-columns.php CHANGED
@@ -38,7 +38,7 @@ add_action( 'manage_ditty_news_ticker_posts_custom_column', 'mtphr_dnt_display_
38
  /**
39
  * Display the custom edit screen columns
40
  *
41
- * @since 1.0
42
  */
43
  function mtphr_dnt_display_columns( $column, $post_id ){
44
 
@@ -81,7 +81,7 @@ function mtphr_dnt_display_columns( $column, $post_id ){
81
  break;
82
 
83
  case 'dnt_function':
84
- echo '<pre>ditty_news_ticker('.$post_id.');</p></pre>';
85
  break;
86
  }
87
  }
38
  /**
39
  * Display the custom edit screen columns
40
  *
41
+ * @since 1.0.5
42
  */
43
  function mtphr_dnt_display_columns( $column, $post_id ){
44
 
81
  break;
82
 
83
  case 'dnt_function':
84
+ echo '<pre><p>&lt;?php if(function_exists(\'ditty_news_ticker\')){ditty_news_ticker('.$post->ID.');} ?&gt;</p></pre>';
85
  break;
86
  }
87
  }
includes/functions.php CHANGED
@@ -28,7 +28,7 @@ function get_mtphr_dnt_ticker( $id='', $class='', $atts=false ) {
28
 
29
  // Get the post
30
  $ticker = get_post( $id );
31
- if( $ticker ) {
32
 
33
  // Save the original $wp_query
34
  global $wp_query;
28
 
29
  // Get the post
30
  $ticker = get_post( $id );
31
+ if( $ticker && $ticker->post_status == 'publish' ) {
32
 
33
  // Save the original $wp_query
34
  global $wp_query;
includes/help.php CHANGED
@@ -109,7 +109,7 @@ function mtphr_dnt_help_sidebar() {
109
 
110
  $sidebar = '<p><strong>'.__('For more information:', 'ditty-news-ticker').'</strong></p>';
111
  $sidebar .= '<p>'.__('Visit the <a href="http://www.metaphorcreations.com" target="_blank">documentation</a> on the Ditty News Ticker website', 'ditty-news-ticker').'</p>';
112
- $sidebar .= '<p>'.__('<strong><a href="http://www.metaphorcreations.com" target="_blnak">View DNT extensions', 'ditty-news-ticker').'</strong></a>';
113
 
114
  return $sidebar;
115
  }
109
 
110
  $sidebar = '<p><strong>'.__('For more information:', 'ditty-news-ticker').'</strong></p>';
111
  $sidebar .= '<p>'.__('Visit the <a href="http://www.metaphorcreations.com" target="_blank">documentation</a> on the Ditty News Ticker website', 'ditty-news-ticker').'</p>';
112
+ $sidebar .= '<p><strong><a href="http://www.metaphorcreations.com" target="_blnak">'.__('View DNT extensions', 'ditty-news-ticker').'</strong></a>';
113
 
114
  return $sidebar;
115
  }
includes/meta-boxes.php CHANGED
@@ -32,7 +32,7 @@ function mtphr_dnt_metabox_types() {
32
  'append' => array(
33
  '_mtphr_dnt_type_link' => array(
34
  'type' => 'html',
35
- 'default' => '<a href="http://dittynewsticker.com/extensions/" target="_blank"><strong>'.__('View all types', 'ditty-news-ticker').'</strong></a>'
36
  )
37
  )
38
  )
@@ -112,13 +112,7 @@ function mtphr_dnt_metabox_modes() {
112
  'id' => '_mtphr_dnt_mode',
113
  'type' => 'metabox_toggle',
114
  'options' => mtphr_dnt_modes_array(),
115
- 'default' => 'scroll',
116
- 'append' => array(
117
- '_mtphr_dnt_mode_link' => array(
118
- 'type' => 'html',
119
- 'default' => '<a href="http://dittynewsticker.com/extensions/" target="_blank"><strong>'.__('View all modes', 'ditty-news-ticker').'</strong></a>'
120
- )
121
- )
122
  );
123
 
124
  /* Create the modes metabox. */
@@ -364,7 +358,7 @@ function mtphr_dnt_mode_metabox_rotate() {
364
  'button' => __('Buttons', 'ditty-news-ticker')
365
  ),
366
  'display' => 'inline',
367
- 'default' => 'numbers'
368
  )
369
  )
370
  );
32
  'append' => array(
33
  '_mtphr_dnt_type_link' => array(
34
  'type' => 'html',
35
+ 'default' => '<a href="http://dittynewsticker.com" target="_blank"><strong>'.__('View all types', 'ditty-news-ticker').'</strong></a>'
36
  )
37
  )
38
  )
112
  'id' => '_mtphr_dnt_mode',
113
  'type' => 'metabox_toggle',
114
  'options' => mtphr_dnt_modes_array(),
115
+ 'default' => 'scroll'
 
 
 
 
 
 
116
  );
117
 
118
  /* Create the modes metabox. */
358
  'button' => __('Buttons', 'ditty-news-ticker')
359
  ),
360
  'display' => 'inline',
361
+ 'default' => 'number'
362
  )
363
  )
364
  );
includes/metaboxer/metaboxer.css CHANGED
@@ -1,30 +1,4 @@
1
- /* Table of Contents
2
-
3
- * Media Uploader
4
- * General
5
- * Fields
6
- * Labels
7
- * Content
8
-
9
- * File
10
- * Lists
11
- * Sorts
12
- * Code
13
- * Radio
14
- * Checkbox
15
- * WYSIWYG
16
- * Farbtastic
17
- * jQuery Slider
18
- * Pattern Select
19
- * Image Select
20
- * Attachments
21
- * Single Image
22
- * Clearfix
23
- * Custom
24
-
25
- */
26
-
27
- /* General
28
  ------------------------------------------------------------ */
29
 
30
  .mtphr-dnt-metaboxer-admin-fields {
@@ -35,13 +9,15 @@
35
  }
36
  .mtphr-dnt-metaboxer-appended {
37
  display: inline;
38
- margin-left: 10px;
 
 
 
 
 
39
  }
40
 
41
-
42
- /* Fields
43
- ------------------------------------------------------------ */
44
-
45
  .mtphr-dnt-metaboxer-field {
46
  margin-bottom: 20px;
47
  }
@@ -51,10 +27,14 @@
51
  .mtphr-dnt-metaboxer-field:last-child {
52
  margin-bottom: 20px;
53
  }
 
 
 
 
 
 
54
 
55
- /* Labels
56
- ------------------------------------------------------------ */
57
-
58
  .mtphr-dnt-metaboxer-label {
59
  vertical-align: top;
60
  width: 20%;
@@ -77,8 +57,7 @@
77
  padding: 0;
78
  }
79
 
80
- /* Content
81
- ------------------------------------------------------------ */
82
  .mtphr-dnt-metaboxer-field-content {
83
  width: 80%;
84
  vertical-align: top;
@@ -93,6 +72,46 @@
93
  width: auto;
94
  }
95
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
96
  /* File
97
  ------------------------------------------------------------ */
98
 
@@ -138,7 +157,82 @@
138
  background-position: 0 -16px;
139
  }
140
 
141
- /* List Item
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
142
  ------------------------------------------------------------ */
143
 
144
  .mtphr-dnt-metaboxer-list > table {
@@ -163,6 +257,13 @@
163
  width: 16px;
164
  padding-top: 4px !important;
165
  }
 
 
 
 
 
 
 
166
  .mtphr-dnt-metaboxer-list-item-handle span,
167
  .mtphr-dnt-metaboxer-list-item-add a,
168
  .mtphr-dnt-metaboxer-list-item-delete a {
@@ -186,6 +287,14 @@
186
  background-position: 0 -16px;
187
  }
188
 
 
 
 
 
 
 
 
 
189
  /* Sorts
190
  ------------------------------------------------------------ */
191
 
@@ -213,41 +322,7 @@
213
  background-position: 0 -16px;
214
  }
215
 
216
- /* Code
217
- ------------------------------------------------------------ */
218
-
219
- .mtphr-dnt-metaboxer-code pre {
220
- margin: 0 0 5px 0;
221
- padding: 10px;
222
- background: #FFF;
223
- border: 1px solid #EEE;
224
- white-space: normal;
225
-
226
- -webkit-border-radius: 5px;
227
- -moz-border-radius: 5px;
228
- border-radius: 5px;
229
- }
230
- .mtphr-dnt-metaboxer-code pre p {
231
- margin: 0;
232
- }
233
-
234
- /* Radio
235
- ------------------------------------------------------------ */
236
-
237
- .mtphr-dnt-metaboxer-radio input {
238
- margin-top: 0;
239
- margin-right: 1px;
240
- }
241
-
242
- /* Checkbox
243
- ------------------------------------------------------------ */
244
-
245
- .mtphr-dnt-metaboxer-checkbox input {
246
- margin-top: 0;
247
- margin-right: 1px;
248
- }
249
-
250
- /* Textarea
251
  ------------------------------------------------------------ */
252
 
253
  .mtphr-dnt-metaboxer-textarea textarea {
@@ -264,261 +339,3 @@
264
  background: #FFF;
265
  }
266
 
267
- /* Farbtastic
268
- ------------------------------------------------------------ */
269
-
270
- .farbtastic_cp {
271
- float: left;
272
- display: none;
273
- }
274
-
275
- /* jQuery Slider
276
- ------------------------------------------------------------ */
277
-
278
- .slider-value {
279
- display: inline;
280
- font-weight: bold;
281
- line-height: 12px;
282
- color: #3D759B;
283
- border: none !important;
284
- margin: 0 0 0 5px;
285
- padding: 0;
286
- }
287
-
288
- /* Pattern Select
289
- ------------------------------------------------------------ */
290
-
291
- .mtphr-dnt-metaboxer-pattern_select select {
292
- margin-bottom: 5px;
293
- }
294
- .mtphr-dnt-metaboxer-pattern-selection {
295
- width: 200px;
296
- height: 100px;
297
- background-repeat: repeat;
298
- }
299
-
300
- /* Image Select
301
- ------------------------------------------------------------ */
302
-
303
- .mtphr-dnt-metaboxer-image-select {
304
- margin-bottom: 10px;
305
- }
306
- a.mtphr-dnt-metaboxer-image-select-link {
307
- display: block;
308
- float: left;
309
- margin: 0 10px 10px 0;
310
- text-decoration: none;
311
- }
312
- a.mtphr-dnt-metaboxer-image-select-link small {
313
- display: block;
314
- text-align: center;
315
- font-weight: bold;
316
- color: #333;
317
- }
318
- a.mtphr-dnt-metaboxer-image-select-link img {
319
- opacity: .5;
320
- -webkit-transition: opacity .2s linear;
321
- -moz-transition: opacity .2s linear;
322
- -o-transition: opacity .2s linear;
323
- -ms-transition: opacity .2s linear;
324
- transition: opacity .2s linear;
325
- }
326
- a.mtphr-dnt-metaboxer-image-select-link.selected img {
327
- opacity: 1;
328
- }
329
-
330
-
331
- /* Attachments
332
- ------------------------------------------------------------ */
333
-
334
- .mtphr-dnt-metaboxer-attachment-container {
335
- margin: 0;
336
- padding: 0;
337
- }
338
- .mtphr-dnt-metaboxer-attachment-buttons {
339
- margin-bottom: 10px;
340
- }
341
- .mtphr-dnt-metaboxer-attachment-links {
342
- opacity: 0;
343
- -webkit-transition: opacity .2s linear;
344
- -moz-transition: opacity .2s linear;
345
- -o-transition: opacity .2s linear;
346
- -ms-transition: opacity .2s linear;
347
- transition: opacity .2s linear;
348
- }
349
- .mtphr-dnt-metaboxer-gallery-attachment:hover .mtphr-dnt-metaboxer-attachment-links,
350
- .mtphr-dnt-metaboxer-single-attachment:hover .mtphr-dnt-metaboxer-attachment-links {
351
- opacity: 1;
352
- }
353
- .mtphr-dnt-metaboxer-attachment-preview,
354
- .mtphr-dnt-metaboxer-attachment-settings,
355
- .mtphr-dnt-metaboxer-attachment-delete {
356
- display: inline-block;
357
- opacity: .5;
358
- -webkit-transition: opacity .2s linear;
359
- -moz-transition: opacity .2s linear;
360
- -o-transition: opacity .2s linear;
361
- -ms-transition: opacity .2s linear;
362
- transition: opacity .2s linear;
363
- }
364
- .mtphr-dnt-metaboxer-attachment-preview:hover,
365
- .mtphr-dnt-metaboxer-attachment-settings:hover,
366
- .mtphr-dnt-metaboxer-attachment-delete:hover {
367
- opacity: 1;
368
- }
369
- .mtphr-dnt-metaboxer-attachment-preview {
370
- position: absolute;
371
- top: 10px;
372
- left: 10px;
373
- width: 17px;
374
- height: 17px;
375
- background: url(images/attachment-preview.png);
376
- }
377
- .mtphr-dnt-metaboxer-attachment-settings {
378
- position: absolute;
379
- top: 10px;
380
- right: 10px;
381
- width: 17px;
382
- height: 17px;
383
- background: url(images/attachment-settings.png);
384
- }
385
- .mtphr-dnt-metaboxer-attachment-delete {
386
- position: absolute;
387
- bottom: 10px;
388
- right: 10px;
389
- width: 14px;
390
- height: 14px;
391
- background: url(images/attachment-delete.png);
392
- }
393
- .mtphr-dnt-metaboxer-attachment-mime-type {
394
- position: absolute;
395
- bottom: 10px;
396
- left: 10px;
397
- }
398
- .mtphr-dnt-metaboxer-attachment-mime-type-vimeo {
399
- width: 20px;
400
- height: 20px;
401
- background: url(images/attachment-vimeo.png);
402
- }
403
- .mtphr-dnt-metaboxer-attachment-mime-type-youtube {
404
- width: 20px;
405
- height: 23px;
406
- background: url(images/attachment-youtube.png);
407
- }
408
- .mtphr-dnt-metaboxer-attachment-mime-type-audio {
409
- width: 20px;
410
- height: 20px;
411
- background: url(images/attachment-audio.png);
412
- }
413
- .mtphr-dnt-metaboxer-attachment-mime-type-video {
414
- width: 20px;
415
- height: 20px;
416
- background: url(images/attachment-video.png);
417
- }
418
- .mtphr-dnt-metaboxer-attachment-mime-type-image {
419
- width: 20px;
420
- height: 20px;
421
- background: url(images/attachment-image.png);
422
- }
423
- .mtphr-dnt-metaboxer-gallery-attachment-container {
424
- width:100%;
425
- margin: 0;
426
- }
427
- .mtphr-dnt-metaboxer-gallery-attachment {
428
- position: relative;
429
- float: left;
430
- width: 120px;
431
- height: 120px;
432
-
433
- margin: 0 10px 10px 0;
434
-
435
- -webkit-border-radius: 5px;
436
- -moz-border-radius: 5px;
437
- border-radius: 5px;
438
-
439
- -moz-box-shadow: 2px 0 0px #000, inset 0 0 3px #DDD;
440
- -webkit-box-shadow: 2px 0 0px #000, inset 0 0 3px #DDD;
441
- box-shadow: 0 0 1px #000;
442
-
443
- opacity: 1;
444
- -webkit-transition: opacity .2s linear;
445
- -moz-transition: opacity .2s linear;
446
- -o-transition: opacity .2s linear;
447
- -ms-transition: opacity .2s linear;
448
- transition: opacity .2s linear;
449
- }
450
- .mtphr-dnt-metaboxer-gallery-attachment:active {
451
- opacity: .5;
452
- }
453
- .mtphr-dnt-metaboxer-gallery-attachment-bg {
454
- width: 120px;
455
- height: 120px;
456
- background-position: center center;
457
- background-size: auto 120px;
458
- -webkit-border-radius: 5px;
459
- -moz-border-radius: 5px;
460
- border-radius: 5px;
461
- }
462
- .mtphr-dnt-metaboxer-gallery-attachment-bg-youtube {
463
- background-size: auto 160px;
464
- }
465
- .mtphr-dnt-metaboxer-gallery-attachment img {
466
- -webkit-border-radius: 5px;
467
- -moz-border-radius: 5px;
468
- border-radius: 5px;
469
- }
470
- .mtphr-dnt-metaboxer-gallery-attachment:active .mtphr-dnt-metaboxer-attachment-links {
471
- opacity: 0;
472
- }
473
- .attachment-mtphr-dnt-metaboxer-gallery-thumb {
474
- cursor: move;
475
- -webkit-border-radius: 5px;
476
- -moz-border-radius: 5px;
477
- border-radius: 5px;
478
- }
479
-
480
- /* Single Image
481
- ------------------------------------------------------------ */
482
-
483
- .mtphr-dnt-metaboxer-single-attachment {
484
- float: left;
485
- position: relative;
486
- margin: 0;
487
- padding: 0;
488
- }
489
- .mtphr-dnt-metaboxer-single-attachment img {
490
- max-width: 90%;
491
- height: auto;
492
- padding: 20px;
493
- margin: 0;
494
-
495
- -webkit-border-radius: 5px;
496
- -moz-border-radius: 5px;
497
- border-radius: 5px;
498
-
499
- -moz-box-shadow: 2px 0 0px #000, inset 0 0 3px #DDD;
500
- -webkit-box-shadow: 2px 0 0px #000, inset 0 0 3px #DDD;
501
- box-shadow: 0 0 1px #000;
502
- }
503
-
504
- /* Clearfix
505
- ------------------------------------------------------------ */
506
-
507
- .clearfix {
508
- *zoom: 1;
509
- }
510
- .clearfix:before,
511
- .clearfix:after {
512
- display: table;
513
- content: "";
514
- }
515
- .clearfix:after {
516
- clear: both;
517
- }
518
-
519
- /* Custom
520
- ------------------------------------------------------------ */
521
-
522
- #mtphr_dnt_global_settings .mtphr-dnt-metaboxer-field-content {
523
- padding-bottom: 0;
524
- }
1
+ /* General - 1.0.2
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2
  ------------------------------------------------------------ */
3
 
4
  .mtphr-dnt-metaboxer-admin-fields {
9
  }
10
  .mtphr-dnt-metaboxer-appended {
11
  display: inline;
12
+ margin-left: 20px;
13
+ }
14
+ .mtphr-dnt-metaboxer-widget-field {
15
+ display: block;
16
+ margin: 0 0 1em;
17
+ padding: 0;
18
  }
19
 
20
+ /* Fields */
 
 
 
21
  .mtphr-dnt-metaboxer-field {
22
  margin-bottom: 20px;
23
  }
27
  .mtphr-dnt-metaboxer-field:last-child {
28
  margin-bottom: 20px;
29
  }
30
+ .mtphr-dnt-metaboxer-field input[type="checkbox"] {
31
+ margin-top: 0;
32
+ }
33
+ .mtphr-dnt-metaboxer-field input[type="radio"] {
34
+ margin-top:-1px;
35
+ }
36
 
37
+ /* Labels */
 
 
38
  .mtphr-dnt-metaboxer-label {
39
  vertical-align: top;
40
  width: 20%;
57
  padding: 0;
58
  }
59
 
60
+ /* Content */
 
61
  .mtphr-dnt-metaboxer-field-content {
62
  width: 80%;
63
  vertical-align: top;
72
  width: auto;
73
  }
74
 
75
+ /* Clearfix */
76
+ .clearfix {
77
+ *zoom: 1;
78
+ }
79
+ .clearfix:before,
80
+ .clearfix:after {
81
+ display: table;
82
+ content: "";
83
+ }
84
+ .clearfix:after {
85
+ clear: both;
86
+ }
87
+
88
+ /* Checkbox
89
+ ------------------------------------------------------------ */
90
+
91
+ .mtphr-dnt-metaboxer-checkbox input {
92
+ margin-top: 0;
93
+ margin-right: 1px;
94
+ }
95
+
96
+ /* Code - 1.0.1
97
+ ------------------------------------------------------------ */
98
+
99
+ .mtphr-dnt-metaboxer-code pre {
100
+ margin: 0 0 5px 0;
101
+ padding: 10px;
102
+ background: #FFF;
103
+ border: 1px solid #EEE;
104
+ white-space: normal;
105
+ word-break: break-all;
106
+
107
+ -webkit-border-radius: 5px;
108
+ -moz-border-radius: 5px;
109
+ border-radius: 5px;
110
+ }
111
+ .mtphr-dnt-metaboxer-code pre p {
112
+ margin: 0;
113
+ }
114
+
115
  /* File
116
  ------------------------------------------------------------ */
117
 
157
  background-position: 0 -16px;
158
  }
159
 
160
+ /* Image
161
+ ------------------------------------------------------------ */
162
+
163
+ .wp-core-ui .mtphr-dnt-metaboxer-image-upload {
164
+ display: none;
165
+ }
166
+ .form-table td.mtphr-dnt-metaboxer-image-display {
167
+ padding-left: 0;
168
+ padding-right: 0;
169
+ }
170
+ .mtphr-dnt-metaboxer-image-display a {
171
+ display: block;
172
+ margin: 0;
173
+ padding: 10px;
174
+ background: #FEFEFE;
175
+ border: 1px solid #EEE;
176
+ white-space: normal;
177
+ text-decoration: none;
178
+
179
+ -webkit-border-radius: 5px;
180
+ -moz-border-radius: 5px;
181
+ border-radius: 5px;
182
+ }
183
+ .mtphr-dnt-metaboxer-image-display img {
184
+ display: block;
185
+ padding: 5px;
186
+ }
187
+ .mtphr-dnt-metaboxer-image-display span {
188
+ text-decoration: none;
189
+ }
190
+ .mtphr-dnt-metaboxer-image-delete {
191
+ width: 16px;
192
+ padding-top: 4px !important;
193
+ }
194
+ .mtphr-dnt-metaboxer-image-delete a {
195
+ display: block;
196
+ text-indent: -9999px;
197
+ width: 16px;
198
+ height: 16px;
199
+ background: url(images/minus-circle.png) no-repeat top;
200
+ }
201
+ .mtphr-dnt-metaboxer-image-delete a:hover {
202
+ background-position: 0 -16px;
203
+ }
204
+
205
+ /* Image Select
206
+ ------------------------------------------------------------ */
207
+
208
+ .mtphr-dnt-metaboxer-image-select {
209
+ margin-bottom: 10px;
210
+ }
211
+ a.mtphr-dnt-metaboxer-image-select-link {
212
+ display: block;
213
+ float: left;
214
+ margin: 0 10px 10px 0;
215
+ text-decoration: none;
216
+ }
217
+ a.mtphr-dnt-metaboxer-image-select-link small {
218
+ display: block;
219
+ text-align: center;
220
+ font-weight: bold;
221
+ color: #333;
222
+ }
223
+ a.mtphr-dnt-metaboxer-image-select-link img {
224
+ opacity: .5;
225
+ -webkit-transition: opacity .2s linear;
226
+ -moz-transition: opacity .2s linear;
227
+ -o-transition: opacity .2s linear;
228
+ -ms-transition: opacity .2s linear;
229
+ transition: opacity .2s linear;
230
+ }
231
+ a.mtphr-dnt-metaboxer-image-select-link.selected img {
232
+ opacity: 1;
233
+ }
234
+
235
+ /* List - 1.0.1
236
  ------------------------------------------------------------ */
237
 
238
  .mtphr-dnt-metaboxer-list > table {
257
  width: 16px;
258
  padding-top: 4px !important;
259
  }
260
+ .mtphr-dnt-metaboxer-list td.mtphr-dnt-metaboxer-list-item-handle {
261
+ padding-left: 0;
262
+ }
263
+ .mtphr-dnt-metaboxer-list td.mtphr-dnt-metaboxer-list-item-add,
264
+ .mtphr-dnt-metaboxer-list td.mtphr-dnt-metaboxer-list-item-delete {
265
+ padding-right: 0;
266
+ }
267
  .mtphr-dnt-metaboxer-list-item-handle span,
268
  .mtphr-dnt-metaboxer-list-item-add a,
269
  .mtphr-dnt-metaboxer-list-item-delete a {
287
  background-position: 0 -16px;
288
  }
289
 
290
+ /* Radio
291
+ ------------------------------------------------------------ */
292
+
293
+ .mtphr-team-members-metaboxer-radio input {
294
+ margin-top: 0;
295
+ margin-right: 1px;
296
+ }
297
+
298
  /* Sorts
299
  ------------------------------------------------------------ */
300
 
322
  background-position: 0 -16px;
323
  }
324
 
325
+ /* Textarea - 1.0.1
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
326
  ------------------------------------------------------------ */
327
 
328
  .mtphr-dnt-metaboxer-textarea textarea {
339
  background: #FFF;
340
  }
341
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/metaboxer/metaboxer.js CHANGED
@@ -1,380 +1,400 @@
1
- /* Table of Contents
2
-
3
- * File
4
- * Lists
5
- * Code
6
- * Metabox toggle
7
-
8
- */
9
-
10
 
11
 
12
 
13
- jQuery(document).ready( function($) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
14
 
15
 
16
 
 
 
 
 
 
 
17
 
18
- /**
19
- * Add file functionality.
20
- *
21
- * @since 1.0.0
22
- */
23
- if( $('.mtphr-dnt-metaboxer-file').length > 0 ) {
24
- mtphr_dnt_metaboxer_files();
25
  }
26
- function mtphr_dnt_metaboxer_files() {
 
 
 
27
 
28
- // Loop through all files to initialize
29
- $('.mtphr-dnt-metaboxer-file').each( function(index) {
30
-
31
- // If there currently isn't a value, show the upload button
32
- if( $(this).find('.mtphr-dnt-metaboxer-file-value').val() == '' ) {
33
- $(this).find('.mtphr-dnt-metaboxer-file-upload').css('display','inline-block');
34
- }
35
- });
36
-
37
- // Custom media upload functionality
38
- $('.mtphr-dnt-metaboxer-file-upload').click(function() {
39
-
40
- // Save the container
41
- var $container = $(this).parent('.mtphr-dnt-metaboxer-field-content');
42
-
43
- var send_attachment_bkp = wp.media.editor.send.attachment;
44
-
45
- wp.media.editor.send.attachment = function( props, attachment ) {
46
-
47
- // Set the field value
48
- $container.find('.mtphr-dnt-metaboxer-file-value').val(attachment.id);
49
-
50
- // Create the display
51
- var data = {
52
- action: 'mtphr_dnt_metaboxer_ajax_file_display',
53
- id: attachment.id,
54
- type: attachment.type,
55
- url: attachment.url,
56
- title: attachment.title,
57
- caption: attachment.caption,
58
- description: attachment.description,
59
- security: mtphr_dnt_metaboxer_vars.security
60
- };
61
-
62
- // since 2.8 ajaxurl is always defined in the admin header and points to admin-ajax.php
63
- jQuery.post( ajaxurl, data, function( response ) {
64
-
65
- // Append the new data
66
- $container.append( response );
67
-
68
- // Hide the upload button
69
- $container.find('.mtphr-dnt-metaboxer-file-upload').hide();
70
- });
71
 
72
- wp.media.editor.send.attachment = send_attachment_bkp;
73
- }
74
-
75
- wp.media.editor.open();
76
 
77
- return false;
78
- });
79
-
80
- $('.mtphr-dnt-metaboxer-file-delete').live('click',function() {
81
-
82
- // Save the container
83
- var $container = $(this).parents('.mtphr-dnt-metaboxer-field-content');
84
-
85
- // Remove the field value
86
- $container.find('.mtphr-dnt-metaboxer-file-value').val('');
87
-
88
- // Remove the current display
89
- $container.find('.mtphr-dnt-metaboxer-file-table').remove();
 
 
 
 
 
 
 
 
 
90
 
91
- // Disply the upload button
92
- $container.find('.mtphr-dnt-metaboxer-file-upload').css('display','inline-block');
93
  });
94
- }
95
 
 
 
 
 
96
 
 
 
 
 
 
 
 
 
 
 
 
 
 
97
 
 
 
 
98
 
99
- /**
100
- * Add list functionality.
101
- *
102
- * @since 1.0.0
103
- */
104
- if( $('.mtphr-dnt-metaboxer-list').length > 0 ) {
105
- mtphr_dnt_metaboxer_lists();
106
- }
107
- function mtphr_dnt_metaboxer_lists() {
108
 
109
- // Loop through all lists to initialize
110
- $('.mtphr-dnt-metaboxer-list').each( function(index) {
 
 
 
111
 
112
- // Set the field order
113
- mtphr_dnt_metaboxer_lists_set_order( $(this) );
114
-
115
- // Add sorting to the items
116
- $(this).sortable( {
117
- handle: '.mtphr-dnt-metaboxer-list-item-handle',
118
- items: '.mtphr-dnt-metaboxer-list-item',
119
- axis: 'y',
120
- helper: function(e, tr) {
121
- var $originals = tr.children();
122
- var $helper = tr.clone();
123
- $helper.children().each(function(index) {
124
- // Set helper cell sizes to match the original sizes
125
- $(this).width($originals.eq(index).width())
126
- });
127
- return $helper;
128
- },
129
- update: function( event, ui ) {
130
-
131
- // Set the field order
132
- mtphr_dnt_metaboxer_lists_set_order( $(this) );
133
- }
134
- });
135
- });
136
-
137
- // Set the list item order
138
- function mtphr_dnt_metaboxer_lists_set_order( $list ) {
139
 
140
- // Set the order of the items
141
- $list.find('.mtphr-dnt-metaboxer-list-item').each( function(i) {
142
-
143
- $(this).find('.mtphr-dnt-metaboxer-list-structure-item').each( function(e) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
144
 
145
- var base = $(this).attr('base');
146
- var field = $(this).attr('field');
147
- $(this).find('input,textarea,select').attr('name', base+'['+i+']['+field+']');
148
- });
149
- });
150
-
151
- // Hide the delete if only one element
152
- if( $list.find('.mtphr-dnt-metaboxer-list-item').length == 1 ) {
153
-
154
- $list.find('.mtphr-dnt-metaboxer-list-item-handle,.mtphr-dnt-metaboxer-list-item-delete').hide();
155
- }
156
- }
157
-
158
- // Add item click
159
- $('.mtphr-dnt-metaboxer-list-item-add').children('a').click( function(e) {
160
- e.preventDefault();
161
 
162
- // Create a new item with blank content
163
- var $parent = $(this).parents('.mtphr-dnt-metaboxer-list-item');
164
- var $new = $parent.clone(true).hide();
165
- $new.find('input,textarea,select').removeAttr('value').removeAttr('checked').removeAttr('selected');
166
- $parent.after($new);
167
- $new.fadeIn();
168
-
169
- // Set the field order
170
- mtphr_dnt_metaboxer_lists_set_order( $(this).parents('.mtphr-dnt-metaboxer-list') );
171
-
172
- // Show the handles
173
- $(this).parents('.mtphr-dnt-metaboxer-list').find('.mtphr-dnt-metaboxer-list-item-handle,.mtphr-dnt-metaboxer-list-item-delete').show();
174
-
175
- // Set the focus to the new input
176
- var inputs = $new.find('input,textarea,select');
177
- $(inputs[0]).focus();
178
  });
179
-
180
- // Delete item click
181
- $('.mtphr-dnt-metaboxer-list-item-delete').children('a').click( function(e) {
182
- e.preventDefault();
183
-
184
- // Fade out the item
185
- $(this).parents('.mtphr-dnt-metaboxer-list-item').fadeOut( function() {
186
-
187
- // Get the list
188
- var $list = $(this).parents('.mtphr-dnt-metaboxer-list');
189
-
190
- // Remove the item
191
- $(this).remove();
192
-
193
- // Set the field order
194
- mtphr_dnt_metaboxer_lists_set_order( $list );
195
- });
196
- });
197
- }
198
 
 
 
199
 
 
 
200
 
 
 
201
 
202
- /**
203
- * Add list functionality.
204
- *
205
- * @since 1.0.0
206
- */
207
- if( $('.mtphr-dnt-metaboxer-sort').length > 0 ) {
208
- mtphr_dnt_metaboxer_sorts();
209
- }
210
- function mtphr_dnt_metaboxer_sorts() {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
211
 
212
- // Loop through all sorts to initialize
213
- $('.mtphr-dnt-metaboxer-sort').each( function(index) {
 
 
 
 
214
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
215
  // Set the field order
216
- //mtphr_dnt_metaboxer_sorts_set_order( $(this) );
 
 
 
 
 
 
 
 
 
 
 
217
 
218
- // Add sorting to the items
219
- $(this).sortable( {
220
- handle: '.mtphr-dnt-metaboxer-sort-item-handle',
221
- items: '.mtphr-dnt-metaboxer-sort-item',
222
- axis: 'y',
223
- helper: function(e, tr) {
224
- var $originals = tr.children();
225
- var $helper = tr.clone();
226
- $helper.children().each(function(index) {
227
- // Set helper cell sizes to match the original sizes
228
- $(this).width($originals.eq(index).width())
229
- });
230
- return $helper;
231
- },
232
- update: function( event, ui ) {
233
-
234
- // Set the field order
235
- //mtphr_dnt_metaboxer_sorts_set_order( $(this) );
236
- }
237
- });
238
  });
239
-
240
- // Set the list item order
241
- /*
242
- function mtphr_dnt_metaboxer_sorts_set_order( $sort ) {
243
 
244
- // Set the order of the items
245
- $list.find('.mtphr-dnt-metaboxer-list-item').each( function(i) {
246
-
247
- $(this).find('.mtphr-dnt-metaboxer-list-structure-item').each( function(e) {
248
-
249
- var base = $(this).attr('base');
250
- var field = $(this).attr('field');
251
- $(this).find('input,textarea,select').attr('name', base+'['+i+']['+field+']');
252
- });
253
- });
254
-
255
- // Hide the delete if only one element
256
- if( $list.find('.mtphr-dnt-metaboxer-list-item').length == 1 ) {
257
-
258
- $list.find('.mtphr-dnt-metaboxer-list-item-handle,.mtphr-dnt-metaboxer-list-item-delete').hide();
259
- }
260
- }
261
- */
262
  }
 
 
 
 
 
 
 
 
 
 
 
 
263
 
 
 
264
 
 
 
265
 
 
 
 
 
 
 
 
 
266
 
267
- /**
268
- * Add code functionality.
269
- *
270
- * @since 1.0.0
271
- */
272
- if( $('.mtphr-dnt-metaboxer-code').length > 0 ) {
273
- mtphr_dnt_metaboxer_codes();
274
- }
275
- function mtphr_dnt_metaboxer_codes() {
276
 
277
- // Select the code on button click
278
- $('.mtphr-dnt-metaboxer-code-select').click( function(e) {
279
- e.preventDefault();
280
-
281
- var $pre = $(this).parents('.mtphr-dnt-metaboxer-code').find('pre');
282
- var refNode = $pre[0];
283
- if ( jQuery.browser.msie ) {
284
- var range = document.body.createTextRange();
285
- range.moveToElementText( refNode );
286
- range.select();
287
- } else if ( jQuery.browser.mozilla || jQuery.browser.opera ) {
288
- var selection = window.getSelection();
289
- var range = document.createRange();
290
- range.selectNodeContents( refNode );
291
- selection.removeAllRanges();
292
- selection.addRange( range );
293
- } else if ( jQuery.browser.safari || jQuery.browser.chrome ) {
294
- var selection = window.getSelection();
295
- selection.setBaseAndExtent( refNode, 0, refNode, 1 );
296
- }
297
- });
298
- }
299
-
 
 
 
 
 
 
 
 
 
 
 
300
 
 
 
301
 
 
 
 
 
 
 
 
 
302
 
303
- /**
304
- * Add metabox toggle functionality.
305
- *
306
- * @since 1.0.0
307
- */
308
- if( $('.mtphr-dnt-metaboxer-field-metabox_toggle').length > 0 ) {
309
- mtphr_dnt_metaboxer_metabox_toggles();
310
  }
311
- function mtphr_dnt_metaboxer_metabox_toggles() {
312
 
313
- $('.mtphr-dnt-metaboxer-field-metabox_toggle').each( function(index) {
314
-
315
- // Create an array to store all the toggled metaboxes
316
- var metaboxes = Array();
317
- $(this).find('.mtphr-dnt-metaboxer-metabox-toggle').each( function(index) {
318
-
319
- // Get the metaboxes and merge into the main array
320
- var m = $(this).attr('metaboxes').split(',');
321
- $.merge( metaboxes, m );
322
- });
323
- var total_metaboxes = metaboxes.length;
324
-
325
- // Hide the toggled metaboxes
326
- mtphr_dnt_metaboxer_metabox_hide();
327
-
328
- // Display the current metaboxes
329
- if( $(this).find('.mtphr-dnt-metaboxer-metabox-toggle.button-primary').length > 0 ) {
330
- $init_button = $(this).find('.mtphr-dnt-metaboxer-metabox-toggle.button-primary');
331
- } else {
332
- $init_button = $(this).find('.mtphr-dnt-metaboxer-metabox-toggle:first');
333
- $init_button.addClass('button-primary');
334
- }
335
- mtphr_dnt_metaboxer_metabox_show( $init_button );
336
-
337
- // Hide the toggled metaboxes
338
- function mtphr_dnt_metaboxer_metabox_hide() {
339
- for( var i=0; i<total_metaboxes; i++ ) {
340
- $('#'+metaboxes[i]).hide();
341
- $('input[name="'+metaboxes[i]+'-hide"]').removeAttr('checked');
342
- }
343
- }
344
-
345
- // Show the selected metaboxes
346
- function mtphr_dnt_metaboxer_metabox_show( $button ) {
347
-
348
- // Get and display the selected metaboxes
349
- var m = $button.attr('metaboxes').split(',');
350
- var t = m.length;
351
-
352
- // Show all the toggled metaboxes
353
- for( var i=0; i<t; i++ ) {
354
- $('#'+m[i]).show();
355
- $('input[name="'+m[i]+'-hide"]').attr('checked', 'checked');
356
- }
357
-
358
- // Store the new value
359
- $button.siblings('input').val($button.attr('href'));
360
- }
361
-
362
- // Select the code on button click
363
- $(this).find('.mtphr-dnt-metaboxer-metabox-toggle').click( function(e) {
364
- e.preventDefault();
365
 
366
- // Hide all the toggled metaboxes
367
- mtphr_dnt_metaboxer_metabox_hide();
368
-
369
- // Show the selected metaboxes
370
- mtphr_dnt_metaboxer_metabox_show( $(this) );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
371
 
372
- // Set the button classes
373
- $(this).siblings('.mtphr-dnt-metaboxer-metabox-toggle').removeClass('button-primary');
374
- $(this).addClass('button-primary');
375
- });
376
- });
377
- }
 
 
 
 
 
378
 
379
 
380
 
1
+ jQuery(document).ready( function($) {
 
 
 
 
 
 
 
 
2
 
3
 
4
 
5
+ /**
6
+ * Add code functionality.
7
+ *
8
+ * @since 1.0.0
9
+ */
10
+ $('.mtphr-dnt-metaboxer-code-select').click( function(e) {
11
+ e.preventDefault();
12
+
13
+ var $pre = $(this).parents('.mtphr-dnt-metaboxer-code').find('pre');
14
+ var refNode = $pre[0];
15
+ if ( jQuery.browser.msie ) {
16
+ var range = document.body.createTextRange();
17
+ range.moveToElementText( refNode );
18
+ range.select();
19
+ } else if ( jQuery.browser.mozilla || jQuery.browser.opera ) {
20
+ var selection = window.getSelection();
21
+ var range = document.createRange();
22
+ range.selectNodeContents( refNode );
23
+ selection.removeAllRanges();
24
+ selection.addRange( range );
25
+ } else if ( jQuery.browser.safari || jQuery.browser.chrome ) {
26
+ var selection = window.getSelection();
27
+ selection.setBaseAndExtent( refNode, 0, refNode, 1 );
28
+ }
29
+ });
30
 
31
 
32
 
33
+ /**
34
+ * Add file functionality.
35
+ *
36
+ * @since 1.0.0
37
+ */
38
+ $('.mtphr-dnt-metaboxer-file').each( function(index) {
39
 
40
+ // If there currently isn't a value, show the upload button
41
+ if( $(this).find('.mtphr-dnt-metaboxer-file-value').val() == '' ) {
42
+ $(this).find('.mtphr-dnt-metaboxer-file-upload').css('display','inline-block');
 
 
 
 
43
  }
44
+ });
45
+
46
+ // Custom media upload functionality
47
+ $('.mtphr-dnt-metaboxer-file-upload').click(function() {
48
 
49
+ // Save the container
50
+ var $container = $(this).parent('.mtphr-dnt-metaboxer-file-contents');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
51
 
52
+ var send_attachment_bkp = wp.media.editor.send.attachment;
 
 
 
53
 
54
+ wp.media.editor.send.attachment = function( props, attachment ) {
55
+
56
+ // Set the field value
57
+ $container.find('.mtphr-dnt-metaboxer-file-value').val(attachment.id);
58
+
59
+ // Create the display
60
+ var data = {
61
+ action: 'mtphr_dnt_metaboxer_ajax_file_display',
62
+ id: attachment.id,
63
+ type: attachment.type,
64
+ url: attachment.url,
65
+ title: attachment.title,
66
+ caption: attachment.caption,
67
+ description: attachment.description,
68
+ security: mtphr_dnt_metaboxer_vars.security
69
+ };
70
+
71
+ // since 2.8 ajaxurl is always defined in the admin header and points to admin-ajax.php
72
+ jQuery.post( ajaxurl, data, function( response ) {
73
+
74
+ // Append the new data
75
+ $container.append( response );
76
 
77
+ // Hide the upload button
78
+ $container.find('.mtphr-dnt-metaboxer-file-upload').hide();
79
  });
 
80
 
81
+ wp.media.editor.send.attachment = send_attachment_bkp;
82
+ }
83
+
84
+ wp.media.editor.open();
85
 
86
+ return false;
87
+ });
88
+
89
+ $('.mtphr-dnt-metaboxer-file-delete').live('click',function() {
90
+
91
+ // Save the container
92
+ var $container = $(this).parents('.mtphr-dnt-metaboxer-file-contents');
93
+
94
+ // Remove the field value
95
+ $container.find('.mtphr-dnt-metaboxer-file-value').val('');
96
+
97
+ // Remove the current display
98
+ $container.find('.mtphr-dnt-metaboxer-file-table').remove();
99
 
100
+ // Disply the upload button
101
+ $container.find('.mtphr-dnt-metaboxer-file-upload').css('display','inline-block');
102
+ });
103
 
104
+
105
+
106
+ /**
107
+ * Add image functionality.
108
+ *
109
+ * @since 1.0.0
110
+ */
111
+ $('.mtphr-dnt-metaboxer-image').each( function(index) {
 
112
 
113
+ // If there currently isn't a value, show the upload button
114
+ if( $(this).find('.mtphr-dnt-metaboxer-image-value').val() == '' ) {
115
+ $(this).find('.mtphr-dnt-metaboxer-image-upload').css('display','inline-block');
116
+ }
117
+ });
118
 
119
+ // Image upload functionality
120
+ $('.mtphr-dnt-metaboxer-image-upload').click(function() {
121
+
122
+ // Save the container
123
+ var $container = $(this).parent('.mtphr-dnt-metaboxer-image-contents');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
124
 
125
+ var send_attachment_bkp = wp.media.editor.send.attachment;
126
+
127
+ wp.media.editor.send.attachment = function( props, attachment ) {
128
+
129
+ // Set the field value
130
+ $container.find('.mtphr-dnt-metaboxer-image-value').val(attachment.id);
131
+
132
+ // Create the display
133
+ var data = {
134
+ action: 'mtphr_dnt_metaboxer_ajax_image_display',
135
+ id: attachment.id,
136
+ type: attachment.type,
137
+ url: attachment.url,
138
+ title: attachment.title,
139
+ caption: attachment.caption,
140
+ description: attachment.description,
141
+ security: mtphr_dnt_metaboxer_vars.security
142
+ };
143
+
144
+ // since 2.8 ajaxurl is always defined in the admin header and points to admin-ajax.php
145
+ jQuery.post( ajaxurl, data, function( response ) {
146
 
147
+ // Append the new data
148
+ $container.append( response );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
149
 
150
+ // Hide the upload button
151
+ $container.find('.mtphr-dnt-metaboxer-image-upload').hide();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
152
  });
153
+
154
+ wp.media.editor.send.attachment = send_attachment_bkp;
155
+ }
156
+
157
+ wp.media.editor.open();
158
+
159
+ return false;
160
+ });
161
+
162
+ $('.mtphr-dnt-metaboxer-image-delete').live('click',function() {
 
 
 
 
 
 
 
 
 
163
 
164
+ // Save the container
165
+ var $container = $(this).parents('.mtphr-dnt-metaboxer-image-contents');
166
 
167
+ // Remove the field value
168
+ $container.find('.mtphr-dnt-metaboxer-image-value').val('');
169
 
170
+ // Remove the current display
171
+ $container.find('.mtphr-dnt-metaboxer-image-table').remove();
172
 
173
+ // Disply the upload button
174
+ $container.find('.mtphr-dnt-metaboxer-image-upload').css('display','inline-block');
175
+ });
176
+
177
+
178
+
179
+
180
+ /**
181
+ * Add image select functionality.
182
+ *
183
+ * @since 1.0
184
+ */
185
+ $('.mtphr-dnt-metaboxer-image-select-link').click( function(e) {
186
+
187
+ e.preventDefault();
188
+
189
+ // Get the value
190
+ var val = $(this).attr('href');
191
+
192
+ // Save the value to the input
193
+ $(this).siblings('input[type="hidden"]').val(val);
194
+
195
+ // Set & remove selected
196
+ $(this).siblings('.mtphr-dnt-metaboxer-image-select-link').removeClass('selected');
197
+ $(this).addClass('selected');
198
+ });
199
+
200
+
201
+
202
+ /**
203
+ * Add list functionality.
204
+ *
205
+ * @since 1.0.0
206
+ */
207
+ $('.mtphr-dnt-metaboxer-list').each( function(index) {
208
+
209
+ // Set the field order
210
+ mtphr_dnt_metaboxer_lists_set_order( $(this) );
211
 
212
+ // Add sorting to the items
213
+ mtphr_dnt_metaboxer_lists_set_sortable( $(this) );
214
+ });
215
+
216
+ // List - add sorting to the items
217
+ function mtphr_dnt_metaboxer_lists_set_sortable( $list ) {
218
 
219
+ $list.sortable( {
220
+ handle: '.mtphr-dnt-metaboxer-list-item-handle',
221
+ items: '.mtphr-dnt-metaboxer-list-item',
222
+ axis: 'y',
223
+ helper: function(e, tr) {
224
+ var $originals = tr.children();
225
+ var $helper = tr.clone();
226
+ $helper.children().each(function(index) {
227
+ // Set helper cell sizes to match the original sizes
228
+ $(this).width($originals.eq(index).width())
229
+ });
230
+ return $helper;
231
+ },
232
+ update: function( event, ui ) {
233
+
234
  // Set the field order
235
+ mtphr_dnt_metaboxer_lists_set_order( $(this) );
236
+ }
237
+ });
238
+ }
239
+
240
+ // List - set the list item order
241
+ function mtphr_dnt_metaboxer_lists_set_order( $list ) {
242
+
243
+ // Set the order of the items
244
+ $list.find('.mtphr-dnt-metaboxer-list-item').each( function(i) {
245
+
246
+ $(this).find('.mtphr-dnt-metaboxer-list-structure-item').each( function(e) {
247
 
248
+ var base = $(this).attr('base');
249
+ var field = $(this).attr('field');
250
+ $(this).find('input,textarea,select').attr('name', base+'['+i+']['+field+']');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
251
  });
252
+ });
 
 
 
253
 
254
+ // Hide the delete if only one element
255
+ if( $list.find('.mtphr-dnt-metaboxer-list-item').length == 1 ) {
256
+
257
+ $list.find('.mtphr-dnt-metaboxer-list-item-handle,.mtphr-dnt-metaboxer-list-item-delete').hide();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
258
  }
259
+ }
260
+
261
+ // List - add item click
262
+ $('.mtphr-dnt-metaboxer-list-item-add').live( 'click', function(e) {
263
+ e.preventDefault();
264
+
265
+ // Create a new item with blank content
266
+ var $parent = $(this).parents('.mtphr-dnt-metaboxer-list-item');
267
+ var $new = $parent.clone(true).hide();
268
+ $new.find('input,textarea,select').removeAttr('value').removeAttr('checked').removeAttr('selected');
269
+ $parent.after($new);
270
+ $new.fadeIn();
271
 
272
+ // Set the field order
273
+ mtphr_dnt_metaboxer_lists_set_order( $(this).parents('.mtphr-dnt-metaboxer-list') );
274
 
275
+ // Show the handles
276
+ $(this).parents('.mtphr-dnt-metaboxer-list').find('.mtphr-dnt-metaboxer-list-item-handle,.mtphr-dnt-metaboxer-list-item-delete').show();
277
 
278
+ // Set the focus to the new input
279
+ var inputs = $new.find('input,textarea,select');
280
+ $(inputs[0]).focus();
281
+ });
282
+
283
+ // List - delete item click
284
+ $('.mtphr-dnt-metaboxer-list-item-delete').live( 'click', function(e) {
285
+ e.preventDefault();
286
 
287
+ // Fade out the item
288
+ $(this).parents('.mtphr-dnt-metaboxer-list-item').fadeOut( function() {
 
 
 
 
 
 
 
289
 
290
+ // Get the list
291
+ var $list = $(this).parents('.mtphr-dnt-metaboxer-list');
292
+
293
+ // Remove the item
294
+ $(this).remove();
295
+
296
+ // Set the field order
297
+ mtphr_dnt_metaboxer_lists_set_order( $list );
298
+ });
299
+ });
300
+
301
+ // List - handle hover
302
+ $('.mtphr-dnt-metaboxer-list-item-handle').live( 'hover', function() {
303
+ mtphr_dnt_metaboxer_lists_set_sortable( $(this).parents('.mtphr-dnt-metaboxer-list') );
304
+ });
305
+
306
+
307
+
308
+ /**
309
+ * Add metabox toggle functionality.
310
+ *
311
+ * @since 1.0.0
312
+ */
313
+ $('.mtphr-dnt-metaboxer-field-metabox_toggle').each( function(index) {
314
+
315
+ // Create an array to store all the toggled metaboxes
316
+ var metaboxes = Array();
317
+ $(this).find('.mtphr-dnt-metaboxer-metabox-toggle').each( function(index) {
318
+
319
+ // Get the metaboxes and merge into the main array
320
+ var m = $(this).attr('metaboxes').split(',');
321
+ $.merge( metaboxes, m );
322
+ });
323
+ var total_metaboxes = metaboxes.length;
324
 
325
+ // Hide the toggled metaboxes
326
+ mtphr_dnt_metaboxer_metabox_hide();
327
 
328
+ // Display the current metaboxes
329
+ if( $(this).find('.mtphr-dnt-metaboxer-metabox-toggle.button-primary').length > 0 ) {
330
+ $init_button = $(this).find('.mtphr-dnt-metaboxer-metabox-toggle.button-primary');
331
+ } else {
332
+ $init_button = $(this).find('.mtphr-dnt-metaboxer-metabox-toggle:first');
333
+ $init_button.addClass('button-primary');
334
+ }
335
+ mtphr_dnt_metaboxer_metabox_show( $init_button );
336
 
337
+ // Hide the toggled metaboxes
338
+ function mtphr_dnt_metaboxer_metabox_hide() {
339
+ for( var i=0; i<total_metaboxes; i++ ) {
340
+ $('#'+metaboxes[i]).hide();
341
+ $('input[name="'+metaboxes[i]+'-hide"]').removeAttr('checked');
342
+ }
 
343
  }
 
344
 
345
+ // Show the selected metaboxes
346
+ function mtphr_dnt_metaboxer_metabox_show( $button ) {
347
+
348
+ // Get and display the selected metaboxes
349
+ var m = $button.attr('metaboxes').split(',');
350
+ var t = m.length;
351
+
352
+ // Show all the toggled metaboxes
353
+ for( var i=0; i<t; i++ ) {
354
+ $('#'+m[i]).show();
355
+ $('input[name="'+m[i]+'-hide"]').attr('checked', 'checked');
356
+ }
357
+
358
+ // Store the new value
359
+ $button.siblings('input').val($button.attr('href'));
360
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
361
 
362
+ // Select the code on button click
363
+ $(this).find('.mtphr-dnt-metaboxer-metabox-toggle').click( function(e) {
364
+ e.preventDefault();
365
+
366
+ // Hide all the toggled metaboxes
367
+ mtphr_dnt_metaboxer_metabox_hide();
368
+
369
+ // Show the selected metaboxes
370
+ mtphr_dnt_metaboxer_metabox_show( $(this) );
371
+
372
+ // Set the button classes
373
+ $(this).siblings('.mtphr-dnt-metaboxer-metabox-toggle').removeClass('button-primary');
374
+ $(this).addClass('button-primary');
375
+ });
376
+ });
377
+
378
+
379
+
380
+ /**
381
+ * Add sort functionality.
382
+ *
383
+ * @since 1.0.1
384
+ */
385
+ $('.mtphr-dnt-metaboxer-sort').each( function(index) {
386
 
387
+ // Add sorting to the items
388
+ $(this).sortable( {
389
+ handle: '.mtphr-dnt-metaboxer-sort-item-handle',
390
+ items: '.mtphr-dnt-metaboxer-sort-item',
391
+ axis: 'y',
392
+ update: function( event, ui ) {
393
+ }
394
+ });
395
+ });
396
+
397
+
398
 
399
 
400
 
includes/metaboxer/metaboxer.php CHANGED
@@ -2,11 +2,9 @@
2
  /**
3
  * Put all the Metaboxer admin function here fields here
4
  *
5
- * @package Ditty News Ticker
6
  * @author Metaphor Creations
7
  * @license http://www.opensource.org/licenses/gpl-license.php GPL v2.0 (or later)
8
- * @link http://www.metaphorcreations.com/plugins/metatools
9
- * @version 1.0.0
10
  */
11
 
12
 
@@ -70,113 +68,6 @@ function mtphr_dnt_metaboxer_container( $field, $context ) {
70
 
71
 
72
 
73
- /**
74
- * Add custom image sizes.
75
- *
76
- * @since 1.0.0
77
- */
78
- if ( function_exists( 'add_image_size' ) ) {
79
-
80
- // Create custom image sizes
81
- add_image_size( 'metaboxer-gallery-thumb', 120, 120, true );
82
- }
83
-
84
-
85
-
86
-
87
- add_action( 'wp_ajax_mtphr_dnt_metaboxer_insert_attachment', 'mtphr_dnt_metaboxer_insert_attachment' );
88
- /**
89
- * Ajax function used to insert a single attachment
90
- *
91
- * @since 1.0.0
92
- */
93
- function mtphr_dnt_metaboxer_insert_attachment() {
94
-
95
- // Get access to the database
96
- global $wpdb;
97
-
98
- // Check the nonce
99
- check_ajax_referer( 'mtphr_dnt_metaboxer_ajax_file_nonce', 'security' );
100
-
101
- // Get variables
102
- $file_id = $_POST['file_ids'];
103
- $file_type = isset( $_POST['file_type'] ) ? $_POST['file_type'] : '';
104
- $file_size = isset( $_POST['file_size'] ) ? $_POST['file_size'] : '';
105
-
106
- $output = '<li class="mtphr-dnt-metaboxer-single-attachment" id="'.$file_id.'">'.wp_get_attachment_image( $file_id, ( $file_size != '' ) ? $file_size : 'thumbnail' );;
107
- $output .= '<div class="mtphr-dnt-metaboxer-attachment-links">';
108
- //$output .= '<a href="'.$file_id.'" class="mtphr-dnt-metaboxer-attachment-preview"></a>';
109
- $output .= '<a href="'.$file_id.'" class="mtphr-dnt-metaboxer-attachment-settings"></a>';
110
- $output .= '<a href="'.$file_id.'" class="mtphr-dnt-metaboxer-attachment-delete"></a>';
111
- $output .= '</div><li>';
112
-
113
- echo $output;
114
-
115
- die(); // this is required to return a proper result
116
- }
117
-
118
-
119
-
120
-
121
- add_action( 'wp_ajax_mtphr_dnt_metaboxer_insert_attachments', 'mtphr_dnt_metaboxer_insert_attachments' );
122
- /**
123
- * Ajax function used to insert multiple attachments
124
- *
125
- * @since 1.0.0
126
- */
127
- function mtphr_dnt_metaboxer_insert_attachments() {
128
-
129
- // Get access to the database
130
- global $wpdb;
131
-
132
- // Check the nonce
133
- check_ajax_referer( 'mtphr_dnt_metaboxer_ajax_file_nonce', 'security' );
134
-
135
- // Get variables
136
- $file_ids = $_POST['file_ids'];
137
-
138
- // Create an array of ids
139
- $files = explode( ',', $file_ids );
140
-
141
- // Create the new files
142
- foreach ( $files as $id ) {
143
- echo mtphr_dnt_metaboxer_thumb( $id, false );
144
- }
145
-
146
- die(); // this is required to return a proper result
147
- }
148
-
149
-
150
-
151
-
152
- add_action( 'wp_ajax_mtphr_dnt_metaboxer_delete_attachments', 'mtphr_dnt_metaboxer_delete_attachments' );
153
- /**
154
- * Ajax function used to delete attachments
155
- *
156
- * @since 1.0.0
157
- */
158
- function mtphr_dnt_metaboxer_delete_attachments() {
159
-
160
- // Get access to the database
161
- global $wpdb;
162
-
163
- // Check the nonce
164
- check_ajax_referer( 'mtphr_dnt_metaboxer_ajax_file_nonce', 'security' );
165
-
166
- // Get variables
167
- $file_ids = $_POST['file_ids'];
168
-
169
- // Create an array of ids
170
- $files = explode( ',', $file_ids );
171
-
172
- // Delete the attachments
173
- foreach ( $files as $id ) {
174
- wp_delete_attachment( $id );
175
- }
176
-
177
- die(); // this is required to return a proper result
178
- }
179
-
180
 
181
  /**
182
  * Append fields
@@ -231,94 +122,10 @@ function mtphr_dnt_metaboxer_append_field( $field ) {
231
  }
232
 
233
 
234
-
235
- /* Table of Contents
236
-
237
- * text
238
- * number
239
- * textarea
240
- * wysiwyg
241
- * checkbox
242
- * radio
243
- * farbtastic
244
- * image
245
- * select
246
- * image_select
247
- * list
248
- * sort
249
- * html
250
- * metabox toggle
251
- * file
252
- * gallery
253
- * code
254
-
255
- */
256
-
257
- /**
258
- * Renders an text field.
259
- *
260
- * @since 1.0.0
261
- */
262
- function mtphr_dnt_metaboxer_text( $field, $value='' ) {
263
- $size = ( isset($field['size']) ) ? $field['size'] : 40;
264
- $before = ( isset($field['before']) ) ? '<span>'.$field['before'].' </span>' : '';
265
- $after = ( isset($field['after']) ) ? '<span> '.$field['after'].'</span>' : '';
266
- $text_align = ( isset($field['text_align']) ) ? ' style="text-align:'.$field['text_align'].'"' : '' ;
267
- $output = $before.'<input name="'.$field['id'].'" id="'.$field['id'].'" type="text" value="'.$value.'" size="'.$size.'"'.$text_align.'>'.$after;
268
- echo $output;
269
-
270
- // Add appended fields
271
- mtphr_dnt_metaboxer_append_field($field);
272
- }
273
-
274
- /**
275
- * Renders an number field.
276
- *
277
- * @since 1.0.0
278
- */
279
- function mtphr_dnt_metaboxer_number( $field, $value='' ) {
280
- $style = ( isset($field['style']) ) ? ' style="'.$field['style'].'"' : '';
281
- $before = ( isset($field['before']) ) ? '<span>'.$field['before'].' </span>' : '';
282
- $after = ( isset($field['after']) ) ? '<span> '.$field['after'].'</span>' : '';
283
- $output = $before.'<input name="'.$field['id'].'" id="'.$field['id'].'" type="number" value="'.$value.'" class="small-text"'.$style.'>'.$after;
284
- echo $output;
285
-
286
- // Add appended fields
287
- mtphr_dnt_metaboxer_append_field($field);
288
- }
289
-
290
- /**
291
- * Renders a textarea custom field.
292
- *
293
- * @since 1.0.0
294
- */
295
- function mtphr_dnt_metaboxer_textarea( $field, $value='' ) {
296
- $rows = ( isset($field['rows']) ) ? $field['rows'] : 5;
297
- $cols = ( isset($field['cols']) ) ? $field['cols'] : 40;
298
- $output = '<textarea name="'.$field['id'].'" id="'.$field['id'].'" rows="'.$rows.'" cols="'.$cols.'">'.$value.'</textarea>';
299
- echo $output;
300
-
301
- // Add appended fields
302
- mtphr_dnt_metaboxer_append_field($field);
303
- }
304
 
305
- /**
306
- * Renders a wysiwyg field.
307
- *
308
- * @since 1.0.0
309
- */
310
- function mtphr_dnt_metaboxer_wysiwyg( $field, $value='' ) {
311
- $settings = array();
312
- $settings['media_buttons'] = true;
313
- $settings['textarea_rows'] = ( isset($field['rows']) ) ? $field['rows'] : 12;
314
- wp_editor( $value, $field['id'], $settings );
315
-
316
- // Add appended fields
317
- mtphr_dnt_metaboxer_append_field($field);
318
- }
319
 
320
  /**
321
- * Renders a checkbox custom field.
322
  *
323
  * @since 1.0.0
324
  */
@@ -357,119 +164,232 @@ function mtphr_dnt_metaboxer_checkbox( $field, $value='' ) {
357
  mtphr_dnt_metaboxer_append_field($field);
358
  }
359
 
 
 
360
  /**
361
- * Renders a radio custom field.
362
  *
363
  * @since 1.0.0
364
  */
365
- function mtphr_dnt_metaboxer_radio( $field, $value='' ) {
366
 
367
- if( isset($field['options']) ) {
368
-
369
- $output = '';
370
- $break = '<br/>';
371
- if ( isset($field['display']) ) {
372
- if( $field['display'] == 'inline' ) {
373
- $break = '&nbsp;&nbsp;&nbsp;&nbsp;';
374
- }
375
- }
376
- foreach( $field['options'] as $i => $option ) {
377
- $checked = ( $value == $i ) ? 'checked="checked"' : '';
378
- $output .= '<label><input name="'.$field['id'].'" id="'.$field['id'].'" type="radio" value="'.$i.'" '.$checked.' /> '.$option.'</label>'.$break;
379
- }
380
  }
381
 
382
- echo $output;
 
 
 
 
383
 
 
 
 
 
 
 
 
 
 
 
 
 
 
384
  // Add appended fields
385
  mtphr_dnt_metaboxer_append_field($field);
386
  }
387
 
 
388
  /**
389
- * Renders a farbtastic custom field.
390
  *
391
  * @since 1.0.0
392
  */
393
- function mtphr_dnt_metaboxer_farbtastic( $field, $value='' ) {
394
- $output = '<div class="farbtastic_cp" id="'.$field['id'].'_cp"></div>';
395
- $output .= '<input name="'.$field['id'].'" id="'.$field['id'].'" type="text" value="'.$value.'" />';
396
- $output .= '<a href="#" class="farbtastic-pick button">Pick Color</a>';
397
- echo $output;
398
 
399
- // Add appended fields
400
- mtphr_dnt_metaboxer_append_field($field);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
401
  }
402
-
 
 
403
  /**
404
- * Renders an image field.
405
  *
406
  * @since 1.0.0
407
  */
408
- function mtphr_dnt_metaboxer_image( $field, $value=false ) {
409
- $button = isset( $field['button'] ) ? $field['button'] : 'Upload Image';
410
- $size = isset( $field['size'] ) ? $field['size'] : 'thumbnail';
411
-
412
- $value = ( $value ) ? $value : false;
413
-
414
- $output = '<div class="mtphr-dnt-metaboxer-attachment-buttons"><a href="#" class="button mtphr-dnt-metaboxer-upload-button">'.$button.'</a></div>';
415
- $output .= '<input class="mtphr-dnt-metaboxer-attachment-limit" type="hidden" value="1" />';
416
- $output .= '<input class="mtphr-dnt-metaboxer-attachment-size" type="hidden" value="'.$size.'" />';
417
- $output .= '<div class="mtphr-dnt-metaboxer-input-container" id="'.$field['id'].'"></div>';
418
- $output .= '<ul id="'.wp_create_nonce( 'mtphr_dnt_metaboxer_ajax_file_nonce' ).'" class="mtphr-dnt-metaboxer-attachment-container clearfix">';
419
- if( $value ) {
420
- if( get_post($value[0]) ) {
421
- $output .= '<li id="'.$value[0].'" class="mtphr-dnt-metaboxer-single-attachment">'.wp_get_attachment_image( $value[0], isset( $field['size'] ) ? $field['size'] : 'thumbnail' );
422
- $output .= '<div class="mtphr-dnt-metaboxer-attachment-links">';
423
- //$output .= '<a href="'.$value[0].'" class="mtphr-dnt-metaboxer-attachment-preview"></a>';
424
- $output .= '<a href="'.$value[0].'" class="mtphr-dnt-metaboxer-attachment-settings"></a>';
425
- $output .= '<a href="'.$value[0].'" class="mtphr-dnt-metaboxer-attachment-delete"></a>';
426
- $output .= '</div>';
427
- $output .= '</li>';
428
- }
429
- }
430
- $output .= '</ul>';
431
- echo $output;
432
 
433
  // Add appended fields
434
  mtphr_dnt_metaboxer_append_field($field);
435
  }
436
 
 
 
437
  /**
438
- * Renders a select field.
439
  *
440
  * @since 1.0.0
441
  */
442
- function mtphr_dnt_metaboxer_select( $field, $value='' ) {
443
-
444
- $before = ( isset($field['before']) ) ? '<span>'.$field['before'].' </span>' : '';
445
- $after = ( isset($field['after']) ) ? '<span> '.$field['after'].'</span>' : '';
446
-
447
- $output = $before.'<select name="'.$field['id'].'" id="'.$field['id'].'">';
448
 
449
- if( $field['options'] ) {
450
-
451
- $key_val = isset( $field['key_val'] ) ? true : false;
452
-
453
- foreach ( $field['options'] as $key => $option ) {
454
- if( is_numeric($key) && !$key_val ) {
455
- $name = ( is_array( $option ) ) ? $option['name'] : $option;
456
- $val = ( is_array( $option ) ) ? $option['value'] : $option;
457
- } else {
458
- $name = $option;
459
- $val = $key;
460
- }
461
- $selected = ( $val == $value ) ? 'selected="selected"' : '';
462
- $output .= '<option value="'.$val.'" '.$selected.'>'.stripslashes( $name ).'</option>';
463
- }
464
  }
465
- $output .= '</select>'.$after;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
466
 
467
- echo $output;
 
 
 
468
 
 
 
 
469
  // Add appended fields
470
  mtphr_dnt_metaboxer_append_field($field);
471
  }
472
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
473
  /**
474
  * Renders an image select
475
  *
@@ -487,10 +407,12 @@ function mtphr_dnt_metaboxer_image_select( $field, $value='' ) {
487
  mtphr_dnt_metaboxer_append_field($field);
488
  }
489
 
 
 
490
  /**
491
  * Renders a list.
492
  *
493
- * @since 1.0.0
494
  */
495
  function mtphr_dnt_metaboxer_list( $field, $value='' ) {
496
 
@@ -520,7 +442,7 @@ function mtphr_dnt_metaboxer_list( $field, $value='' ) {
520
  }
521
 
522
  // If nothing is being output make sure one field is showing
523
- if( $value == '' ) {
524
  $structure = mtphr_dnt_metaboxer_list_structure( 0, $field );
525
  $output .= '<tr class="mtphr-dnt-metaboxer-list-item"><td class="mtphr-dnt-metaboxer-list-item-handle"><span></span></td>'.$structure.$buttons.'</tr>';
526
  }
@@ -533,11 +455,7 @@ function mtphr_dnt_metaboxer_list( $field, $value='' ) {
533
  mtphr_dnt_metaboxer_append_field($field);
534
  }
535
 
536
- /**
537
- * Add the list structure
538
- *
539
- * @since 1.0.0
540
- */
541
  function mtphr_dnt_metaboxer_list_structure( $pos, $fields, $m_value='' ) {
542
 
543
  $main_id = $fields['id'];
@@ -579,10 +497,130 @@ function mtphr_dnt_metaboxer_list_structure( $pos, $fields, $m_value='' ) {
579
  }
580
  }
581
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
582
  /**
583
  * Renders a sort.
584
  *
585
- * @since 1.0.4
586
  */
587
  function mtphr_dnt_metaboxer_sort( $field, $value='' ) {
588
 
@@ -641,45 +679,20 @@ function mtphr_dnt_metaboxer_sort( $field, $value='' ) {
641
  mtphr_dnt_metaboxer_append_field($field);
642
  }
643
 
644
- /**
645
- * Renders an html field.
646
- *
647
- * @since 1.0.0
648
- */
649
- function mtphr_dnt_metaboxer_html( $field, $value='' ) {
650
-
651
- // Echo the html
652
- echo $value;
653
-
654
- // Add appended fields
655
- mtphr_dnt_metaboxer_append_field($field);
656
- }
657
 
658
  /**
659
- * Renders a metabox toggle.
660
  *
661
- * @since 1.0.0
662
  */
663
- function mtphr_dnt_metaboxer_metabox_toggle( $field, $value='' ) {
664
-
665
- if( isset($field['options']) ) {
666
-
667
- $output = '';
668
- $output .= '<input type="hidden" id="'.$field['id'].'" name="'.$field['id'].'" value="'.$value.'" />';
669
-
670
- foreach( $field['options'] as $i => $option ) {
671
-
672
- $button = $option['button'];
673
- $metaboxes = $option['metaboxes'];
674
- $metabox_list = join( ',', $metaboxes );
675
-
676
- // Create a button
677
- $selected = ( $value == $i ) ? ' button-primary' : '';
678
- $output .= '<a href="'.$i.'" metaboxes="'.$metabox_list.'" class="mtphr-dnt-metaboxer-metabox-toggle button'.$selected.'">'.$button.'</a>&nbsp;';
679
- }
680
-
681
- echo $output;
682
- }
683
 
684
  // Add appended fields
685
  mtphr_dnt_metaboxer_append_field($field);
@@ -687,243 +700,38 @@ function mtphr_dnt_metaboxer_metabox_toggle( $field, $value='' ) {
687
 
688
 
689
 
690
-
691
  /**
692
- * Redners a file attachment
693
  *
694
  * @since 1.0.0
695
  */
696
- function mtphr_dnt_metaboxer_file( $field, $value='' ) {
697
-
698
- // Check if there's actually a file
699
- $file = false;
700
- if( $value != '' ) {
701
- $file = get_post( $value );
702
- }
703
-
704
- // If there isn't a file reset the value
705
- if( !$file ) {
706
- $value = '';
707
- }
708
- ?>
709
-
710
- <input class="mtphr-dnt-metaboxer-file-value" type="hidden" id="<?php echo $field['id']; ?>" name="<?php echo $field['id']; ?>" value="<?php echo $value; ?>" />
711
-
712
- <?php
713
- echo isset( $field['button'] ) ? '<a href="#" class="button mtphr-dnt-metaboxer-file-upload">'.$field['button'].'</a>' : '<a href="#" class="button custom-media-upload">Insert File</a>';
714
-
715
- if( $file ) {
716
 
717
- $type = explode( '/', $file->post_mime_type );
718
-
719
- // Display the file
720
- echo mtphr_dnt_metaboxer_file_display( $file->ID, $type[0], $file->guid, $file->post_title, $file -> post_excerpt, $file->post_content );
721
- }
722
-
723
  // Add appended fields
724
  mtphr_dnt_metaboxer_append_field($field);
725
  }
726
 
727
- add_action( 'wp_ajax_mtphr_dnt_metaboxer_ajax_file_display', 'mtphr_dnt_metaboxer_ajax_file_display' );
728
- /**
729
- * Ajax function used to delete attachments
730
- *
731
- * @since 1.0.0
732
- */
733
- function mtphr_dnt_metaboxer_ajax_file_display() {
734
-
735
- // Get access to the database
736
- global $wpdb;
737
-
738
- // Check the nonce
739
- check_ajax_referer( 'mtphr_dnt', 'security' );
740
-
741
- // Get variables
742
- $id = $_POST['id'];
743
- $type = $_POST['type'];
744
- $url = $_POST['url'];
745
- $title = $_POST['title'];
746
- $caption = $_POST['caption'];
747
- $description = $_POST['description'];
748
-
749
- // Display the file
750
- mtphr_dnt_metaboxer_file_display( $id, $type, $url, $title, $caption, $description );
751
-
752
- die(); // this is required to return a proper result
753
- }
754
-
755
- // Display the file
756
- function mtphr_dnt_metaboxer_file_display( $id, $type, $url, $title, $caption, $description ) {
757
-
758
- $src = '';
759
- switch( $type ) {
760
-
761
- case 'image':
762
- $att = wp_get_attachment_image_src( $id, 'thumbnail' );
763
- $src = $att[0];
764
- break;
765
-
766
- case 'application':
767
- $att = wp_get_attachment_image_src( $id, 'thumbnail', true );
768
- $src = $att[0];
769
- break;
770
- }
771
- ?>
772
- <table class="mtphr-dnt-metaboxer-file-table">
773
- <tr>
774
- <td class="mtphr-dnt-metaboxer-file-display">
775
- <a href="<?php echo $url; ?>" target="_blank" class="clearfix">
776
- <img class="custom_media_image" src="<?php echo $src; ?>" />
777
- <span class="mtphr-dnt-metaboxer-file-title"><strong>Title:</strong> <?php echo $title; ?></span><br/>
778
- <?php if( $caption != '' ) { ?>
779
- <span class="mtphr-dnt-metaboxer-file-caption"><strong>Caption:</strong> <?php echo $caption; ?></span><br/>
780
- <?php }
781
- if( $description != '' ) { ?>
782
- <span class="mtphr-dnt-metaboxer-file-description"><strong>Description:</strong> <?php echo $description; ?></span>
783
- <?php } ?>
784
- </a>
785
- </td>
786
- <td class="mtphr-dnt-metaboxer-file-delete">
787
- <a href="#"></a>
788
- </td>
789
- </tr>
790
- </table>
791
- <?php
792
- }
793
-
794
-
795
 
796
 
797
  /**
798
- * Render a gallery attachment
799
  *
800
  * @since 1.0.0
801
  */
802
- function mtphr_dnt_metaboxer_gallery( $field, $value='' ) {
803
-
804
- /* Create the buttons */
805
- $button = isset( $field['button'] ) ? $field['button'] : 'Insert Media';
806
-
807
- $output = '<div class="mtphr-dnt-metaboxer-attachment-buttons"><a href="#" class="button mtphr-dnt-metaboxer-upload-button">'.$button.'</a></div>';
808
-
809
- /* If there is a file limit */
810
- if ( isset( $field['limit'] ) ) {
811
- $output .= '<input class="mtphr-dnt-metaboxer-attachment-limit" type="hidden" value="'.$field['limit'].'" />';
812
- }
813
- $output .= '<div class="mtphr-dnt-metaboxer-input-container" id="'.$field['id'].'"></div>';
814
- $output .= '<ul id="'.wp_create_nonce( 'mtphr_dnt_metaboxer_ajax_file_nonce' ).'" class="mtphr-dnt-metaboxer-gallery-attachment-container mtphr-dnt-metaboxer-attachment-container clearfix">';
815
-
816
- /* Loop through the existing attachments */
817
- if( $value != '' ){
818
- foreach( $value as $id ) {
819
- $output .= mtphr_dnt_metaboxer_thumb( $id );
820
- }
821
- }
822
- $output .= '</ul>';
823
- echo $output;
824
 
825
  // Add appended fields
826
  mtphr_dnt_metaboxer_append_field($field);
827
  }
828
 
829
- /**
830
- * Create the gallery thumbnail containers.
831
- *
832
- * @since 1.0.0
833
- */
834
- function mtphr_dnt_metaboxer_thumb( $id, $preview=true ) {
835
-
836
- $html = '';
837
- $attachment = get_post( $id );
838
- $nonce = wp_create_nonce( 'mtphr_dnt_metaboxer_ajax_file_nonce' );
839
-
840
- if ( $attachment ) {
841
-
842
- $mime = $attachment->post_mime_type;
843
-
844
- $html = '<li id="'.$id.'" class="mtphr-dnt-metaboxer-gallery-attachment mtphr-dnt-metaboxer-sort-container clearfix">';
845
-
846
- switch ( $mime ) {
847
-
848
- case 'image/jpeg':
849
- $thumb = wp_get_attachment_image_src( $id, 'metaboxer-gallery-thumb' );
850
- $html .= '<div class="mtphr-dnt-metaboxer-gallery-attachment-bg mtphr-dnt-metaboxer-gallery-attachment-bg-image" style="background-image:url('.$thumb[0].');"></div>';
851
- $html .= '<div class="mtphr-dnt-metaboxer-attachment-mime-type mtphr-dnt-metaboxer-attachment-mime-type-image"></div>';
852
- break;
853
-
854
- case 'image/png':
855
- $thumb = wp_get_attachment_image_src( $id, 'metaboxer-gallery-thumb' );
856
- $html .= '<div class="mtphr-dnt-metaboxer-gallery-attachment-bg mtphr-dnt-metaboxer-gallery-attachment-bg-image" style="background-image:url('.$thumb[0].');"></div>';
857
- $html .= '<div class="mtphr-dnt-metaboxer-attachment-mime-type mtphr-dnt-metaboxer-attachment-mime-type-image"></div>';
858
- break;
859
-
860
- case 'application/pdf':
861
- $thumb = wp_get_attachment_image_src( $id, false, true );
862
- $html .= '<div class="mtphr-dnt-metaboxer-gallery-attachment-bg mtphr-dnt-metaboxer-gallery-attachment-bg-pdf" style="background-image:url('.$thumb[0].');"></div>';
863
- $html .= '<div class="mtphr-dnt-metaboxer-attachment-mime-type mtphr-dnt-metaboxer-attachment-mime-type-pdf"></div>';
864
- break;
865
-
866
- case 'application/zip':
867
- $thumb = wp_get_attachment_image_src( $id, false, true );
868
- $html .= '<div class="mtphr-dnt-metaboxer-gallery-attachment-bg mtphr-dnt-metaboxer-gallery-attachment-bg-zip" style="background-image:url('.$thumb[0].');"></div>';
869
- $html .= '<div class="mtphr-dnt-metaboxer-attachment-mime-type mtphr-dnt-metaboxer-attachment-mime-type-zip"></div>';
870
- break;
871
-
872
- case 'audio/mpeg':
873
- $image_id = get_post_meta( $id, '_attachment_poster_image', true );
874
- $default = ( !$image_id || $image_id=='none' ) ? true : false;
875
- $thumb = ( $default ) ? wp_get_attachment_image_src( $id, false, true ) : wp_get_attachment_image_src( $image_id, 'metaboxer-gallery-thumb' );
876
- $html .= '<div class="mtphr-dnt-metaboxer-gallery-attachment-bg mtphr-dnt-metaboxer-gallery-attachment-bg-audio" style="background-image:url('.$thumb[0].');"></div>';
877
- $html .= '<div class="mtphr-dnt-metaboxer-attachment-mime-type mtphr-dnt-metaboxer-attachment-mime-type-audio"></div>';
878
- break;
879
-
880
- case 'video/mp4':
881
- $image_id = get_post_meta( $id, '_attachment_poster_image', true );
882
- $default = ( !$image_id || $image_id=='none' ) ? true : false;
883
- $thumb = ( $default ) ? wp_get_attachment_image_src( $id, false, true ) : wp_get_attachment_image_src( $image_id, 'metaboxer-gallery-thumb' );
884
- $html .= '<div class="mtphr-dnt-metaboxer-gallery-attachment-bg mtphr-dnt-metaboxer-gallery-attachment-bg-video" style="background-image:url('.$thumb[0].');"></div>';
885
- $html .= '<div class="mtphr-dnt-metaboxer-attachment-mime-type mtphr-dnt-metaboxer-attachment-mime-type-video"></div>';
886
- break;
887
-
888
- case 'video/m4v':
889
- $image_id = get_post_meta( $id, '_attachment_poster_image', true );
890
- $default = ( !$image_id || $image_id=='none' ) ? true : false;
891
- $thumb = ( $default ) ? wp_get_attachment_image_src( $id, false, true ) : wp_get_attachment_image_src( $image_id, 'metaboxer-gallery-thumb' );
892
- $html .= '<div class="mtphr-dnt-metaboxer-gallery-attachment-bg mtphr-dnt-metaboxer-gallery-attachment-bg-video" style="background-image:url('.$thumb[0].');"></div>';
893
- $html .= '<div class="mtphr-dnt-metaboxer-attachment-mime-type mtphr-dnt-metaboxer-attachment-mime-type-video"></div>';
894
- break;
895
-
896
- case 'vimeo':
897
- $thumb = get_post_meta( $id, '_video_thumb_large', true );
898
- $html .= '<div class="mtphr-dnt-metaboxer-gallery-attachment-bg mtphr-dnt-metaboxer-gallery-attachment-bg-vimeo" style="background-image:url('.$thumb.');"></div>';
899
- $html .= '<div class="mtphr-dnt-metaboxer-attachment-mime-type mtphr-dnt-metaboxer-attachment-mime-type-vimeo"></div>';
900
- break;
901
-
902
- case 'youtube':
903
- $thumb = get_post_meta( $id, '_video_thumb_large', true );
904
- $html .= '<div class="mtphr-dnt-metaboxer-gallery-attachment-bg mtphr-dnt-metaboxer-gallery-attachment-bg-youtube" style="background-image:url('.$thumb.');"></div>';
905
- $html .= '<div class="mtphr-dnt-metaboxer-attachment-mime-type mtphr-dnt-metaboxer-attachment-mime-type-youtube"></div>';
906
- break;
907
-
908
- default:
909
- // Call the function to display the custom field
910
- call_user_func( 'mtphr_dnt_metaboxer_'.str_replace('%/%','_',$mime).'_thumb', $id, $nonce );
911
- $html .= $mime;
912
- break;
913
- }
914
-
915
- $html .= '<div class="mtphr-dnt-metaboxer-attachment-links">';
916
- //$html .= '<a href="'.$id.'" rel="attachment_preview" class="mtphr-dnt-metaboxer-attachment-preview"></a>';
917
- $html .= '<a href="'.$id.'" class="mtphr-dnt-metaboxer-attachment-settings"></a>';
918
- $html .= '<a href="'.$id.'" class="mtphr-dnt-metaboxer-attachment-delete"></a>';
919
- $html .= '</div>';
920
-
921
- $html .= '</li>';
922
- }
923
-
924
- return $html;
925
- }
926
-
927
 
928
 
929
 
@@ -944,7 +752,7 @@ function mtphr_dnt_metaboxer_code( $field, $value='' ) {
944
  // Display the function code
945
  } elseif( $field['id'] == '_mtphr_dnt_function' ) {
946
 
947
- echo '<pre><p>ditty_news_ticker('.$post->ID.');</p></pre>';
948
  }
949
 
950
  // Display a "Select All" button
2
  /**
3
  * Put all the Metaboxer admin function here fields here
4
  *
5
+ * @package Ditty News Ticker
6
  * @author Metaphor Creations
7
  * @license http://www.opensource.org/licenses/gpl-license.php GPL v2.0 (or later)
 
 
8
  */
9
 
10
 
68
 
69
 
70
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
71
 
72
  /**
73
  * Append fields
122
  }
123
 
124
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
125
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
126
 
127
  /**
128
+ * Renders a checkbox.
129
  *
130
  * @since 1.0.0
131
  */
164
  mtphr_dnt_metaboxer_append_field($field);
165
  }
166
 
167
+
168
+
169
  /**
170
+ * Renders a file attachment
171
  *
172
  * @since 1.0.0
173
  */
174
+ function mtphr_dnt_metaboxer_file( $field, $value='' ) {
175
 
176
+ // Check if there's actually a file
177
+ $file = false;
178
+ if( $value != '' ) {
179
+ $file = get_post( $value );
 
 
 
 
 
 
 
 
 
180
  }
181
 
182
+ // If there isn't a file reset the value
183
+ if( !$file ) {
184
+ $value = '';
185
+ }
186
+ ?>
187
 
188
+ <input class="mtphr-dnt-metaboxer-file-value" type="hidden" id="<?php echo $field['id']; ?>" name="<?php echo $field['id']; ?>" value="<?php echo $value; ?>" />
189
+
190
+ <?php
191
+ echo isset( $field['button'] ) ? '<a href="#" class="button mtphr-dnt-metaboxer-file-upload">'.$field['button'].'</a>' : '<a href="#" class="button custom-media-upload">Insert File</a>';
192
+
193
+ if( $file ) {
194
+
195
+ $type = explode( '/', $file->post_mime_type );
196
+
197
+ // Display the file
198
+ echo mtphr_dnt_metaboxer_file_display( $file->ID, $type[0], $file->guid, $file->post_title, $file -> post_excerpt, $file->post_content );
199
+ }
200
+
201
  // Add appended fields
202
  mtphr_dnt_metaboxer_append_field($field);
203
  }
204
 
205
+ add_action( 'wp_ajax_mtphr_dnt_metaboxer_ajax_file_display', 'mtphr_dnt_metaboxer_ajax_file_display' );
206
  /**
207
+ * Ajax function used to delete attachments
208
  *
209
  * @since 1.0.0
210
  */
211
+ function mtphr_dnt_metaboxer_ajax_file_display() {
 
 
 
 
212
 
213
+ // Get access to the database
214
+ global $wpdb;
215
+
216
+ // Check the nonce
217
+ check_ajax_referer( 'mtphr_dnt', 'security' );
218
+
219
+ // Get variables
220
+ $id = $_POST['id'];
221
+ $type = $_POST['type'];
222
+ $url = $_POST['url'];
223
+ $title = $_POST['title'];
224
+ $caption = $_POST['caption'];
225
+ $description = $_POST['description'];
226
+
227
+ // Display the file
228
+ mtphr_dnt_metaboxer_file_display( $id, $type, $url, $title, $caption, $description );
229
+
230
+ die(); // this is required to return a proper result
231
+ }
232
+
233
+ // Display the file
234
+ function mtphr_dnt_metaboxer_file_display( $id, $type, $url, $title, $caption, $description ) {
235
+
236
+ $src = '';
237
+ switch( $type ) {
238
+
239
+ case 'image':
240
+ $att = wp_get_attachment_image_src( $id, 'thumbnail' );
241
+ $src = $att[0];
242
+ break;
243
+
244
+ case 'application':
245
+ $att = wp_get_attachment_image_src( $id, 'thumbnail', true );
246
+ $src = $att[0];
247
+ break;
248
+ }
249
+ ?>
250
+ <table class="mtphr-dnt-metaboxer-file-table">
251
+ <tr>
252
+ <td class="mtphr-dnt-metaboxer-file-display">
253
+ <a href="<?php echo $url; ?>" target="_blank" class="clearfix">
254
+ <img class="custom_media_image" src="<?php echo $src; ?>" />
255
+ <span class="mtphr-dnt-metaboxer-file-title"><strong>Title:</strong> <?php echo $title; ?></span><br/>
256
+ <?php if( $caption != '' ) { ?>
257
+ <span class="mtphr-dnt-metaboxer-file-caption"><strong>Caption:</strong> <?php echo $caption; ?></span><br/>
258
+ <?php }
259
+ if( $description != '' ) { ?>
260
+ <span class="mtphr-dnt-metaboxer-file-description"><strong>Description:</strong> <?php echo $description; ?></span>
261
+ <?php } ?>
262
+ </a>
263
+ </td>
264
+ <td class="mtphr-dnt-metaboxer-file-delete">
265
+ <a href="#"></a>
266
+ </td>
267
+ </tr>
268
+ </table>
269
+ <?php
270
  }
271
+
272
+
273
+
274
  /**
275
+ * Renders an html field.
276
  *
277
  * @since 1.0.0
278
  */
279
+ function mtphr_dnt_metaboxer_html( $field, $value='' ) {
280
+
281
+ // Echo the html
282
+ echo $value;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
283
 
284
  // Add appended fields
285
  mtphr_dnt_metaboxer_append_field($field);
286
  }
287
 
288
+
289
+
290
  /**
291
+ * Renders an image attachment
292
  *
293
  * @since 1.0.0
294
  */
295
+ function mtphr_dnt_metaboxer_image( $field, $value='' ) {
 
 
 
 
 
296
 
297
+ // Check if there's actually a file
298
+ $image = false;
299
+ if( $value != '' ) {
300
+ $image = get_post( $value );
 
 
 
 
 
 
 
 
 
 
 
301
  }
302
+
303
+ // If there isn't a file reset the value
304
+ if( !$image ) {
305
+ $value = '';
306
+ }
307
+ ?>
308
+
309
+ <div class="mtphr-dnt-metaboxer-image-contents">
310
+ <input class="mtphr-dnt-metaboxer-image-value" type="hidden" id="<?php echo $field['id']; ?>" name="<?php echo $field['id']; ?>" value="<?php echo $value; ?>" />
311
+
312
+ <?php
313
+ echo isset( $field['button'] ) ? '<a href="#" class="button mtphr-dnt-metaboxer-image-upload">'.$field['button'].'</a>' : '<a href="#" class="button mtphr-dnt-metaboxer-image-upload">Insert Image</a>';
314
+
315
+ if( $image ) {
316
+
317
+ $type = explode( '/', $image->post_mime_type );
318
 
319
+ // Display the file
320
+ echo mtphr_dnt_metaboxer_image_display( $image->ID, $type[0], $image->guid, $image->post_title, $image -> post_excerpt, $image->post_content );
321
+ }
322
+ ?>
323
 
324
+ </div>
325
+
326
+ <?php
327
  // Add appended fields
328
  mtphr_dnt_metaboxer_append_field($field);
329
  }
330
 
331
+ add_action( 'wp_ajax_mtphr_dnt_metaboxer_ajax_image_display', 'mtphr_dnt_metaboxer_ajax_image_display' );
332
+ /**
333
+ * Ajax function used to delete attachments
334
+ *
335
+ * @since 1.0.0
336
+ */
337
+ function mtphr_dnt_metaboxer_ajax_image_display() {
338
+
339
+ // Get access to the database
340
+ global $wpdb;
341
+
342
+ // Check the nonce
343
+ check_ajax_referer( 'neuron', 'security' );
344
+
345
+ // Get variables
346
+ $id = $_POST['id'];
347
+ $type = $_POST['type'];
348
+ $url = $_POST['url'];
349
+ $title = $_POST['title'];
350
+ $caption = $_POST['caption'];
351
+ $description = $_POST['description'];
352
+
353
+ // Display the file
354
+ mtphr_dnt_metaboxer_image_display( $id, $type, $url, $title, $caption, $description );
355
+
356
+ die(); // this is required to return a proper result
357
+ }
358
+
359
+ // Display the file
360
+ function mtphr_dnt_metaboxer_image_display( $id, $type, $url, $title, $caption, $description ) {
361
+
362
+ $src = '';
363
+ switch( $type ) {
364
+
365
+ case 'image':
366
+ $att = wp_get_attachment_image_src( $id, 'thumbnail' );
367
+ $src = $att[0];
368
+ break;
369
+
370
+ case 'application':
371
+ $att = wp_get_attachment_image_src( $id, 'thumbnail', true );
372
+ $src = $att[0];
373
+ break;
374
+ }
375
+ ?>
376
+ <table class="mtphr-dnt-metaboxer-image-table">
377
+ <tr>
378
+ <td class="mtphr-dnt-metaboxer-image-display">
379
+ <a href="<?php echo esc_url( get_edit_post_link( $id ) ) ?>" target="_blank" class="clearfix">
380
+ <img src="<?php echo $src; ?>" />
381
+ </a>
382
+ </td>
383
+ <td class="mtphr-dnt-metaboxer-image-delete">
384
+ <a href="#"></a>
385
+ </td>
386
+ </tr>
387
+ </table>
388
+ <?php
389
+ }
390
+
391
+
392
+
393
  /**
394
  * Renders an image select
395
  *
407
  mtphr_dnt_metaboxer_append_field($field);
408
  }
409
 
410
+
411
+
412
  /**
413
  * Renders a list.
414
  *
415
+ * @since 1.0.2
416
  */
417
  function mtphr_dnt_metaboxer_list( $field, $value='' ) {
418
 
442
  }
443
 
444
  // If nothing is being output make sure one field is showing
445
+ if( $value == '' || count($value) == 0 ) {
446
  $structure = mtphr_dnt_metaboxer_list_structure( 0, $field );
447
  $output .= '<tr class="mtphr-dnt-metaboxer-list-item"><td class="mtphr-dnt-metaboxer-list-item-handle"><span></span></td>'.$structure.$buttons.'</tr>';
448
  }
455
  mtphr_dnt_metaboxer_append_field($field);
456
  }
457
 
458
+ // Add the list structure
 
 
 
 
459
  function mtphr_dnt_metaboxer_list_structure( $pos, $fields, $m_value='' ) {
460
 
461
  $main_id = $fields['id'];
497
  }
498
  }
499
 
500
+
501
+
502
+ /**
503
+ * Renders a metabox toggle.
504
+ *
505
+ * @since 1.0.0
506
+ */
507
+ function mtphr_dnt_metaboxer_metabox_toggle( $field, $value='' ) {
508
+
509
+ if( isset($field['options']) ) {
510
+
511
+ $output = '';
512
+ $output .= '<input type="hidden" id="'.$field['id'].'" name="'.$field['id'].'" value="'.$value.'" />';
513
+
514
+ foreach( $field['options'] as $i => $option ) {
515
+
516
+ $button = $option['button'];
517
+ $metaboxes = $option['metaboxes'];
518
+ $metabox_list = join( ',', $metaboxes );
519
+
520
+ // Create a button
521
+ $selected = ( $value == $i ) ? ' button-primary' : '';
522
+ $output .= '<a href="'.$i.'" metaboxes="'.$metabox_list.'" class="mtphr-dnt-metaboxer-metabox-toggle button'.$selected.'">'.$button.'</a>&nbsp;';
523
+ }
524
+
525
+ echo $output;
526
+ }
527
+
528
+ // Add appended fields
529
+ mtphr_dnt_metaboxer_append_field($field);
530
+ }
531
+
532
+
533
+
534
+ /**
535
+ * Renders an number field.
536
+ *
537
+ * @since 1.0.0
538
+ */
539
+ function mtphr_dnt_metaboxer_number( $field, $value='' ) {
540
+ $style = ( isset($field['style']) ) ? ' style="'.$field['style'].'"' : '';
541
+ $before = ( isset($field['before']) ) ? '<span>'.$field['before'].' </span>' : '';
542
+ $after = ( isset($field['after']) ) ? '<span> '.$field['after'].'</span>' : '';
543
+ $output = $before.'<input name="'.$field['id'].'" id="'.$field['id'].'" type="number" value="'.$value.'" class="small-text"'.$style.'>'.$after;
544
+ echo $output;
545
+
546
+ // Add appended fields
547
+ mtphr_dnt_metaboxer_append_field($field);
548
+ }
549
+
550
+
551
+
552
+ /**
553
+ * Renders a radio custom field.
554
+ *
555
+ * @since 1.0.0
556
+ */
557
+ function mtphr_dnt_metaboxer_radio( $field, $value='' ) {
558
+
559
+ if( isset($field['options']) ) {
560
+
561
+ $output = '';
562
+ $break = '<br/>';
563
+ if ( isset($field['display']) ) {
564
+ if( $field['display'] == 'inline' ) {
565
+ $break = '&nbsp;&nbsp;&nbsp;&nbsp;';
566
+ }
567
+ }
568
+ foreach( $field['options'] as $i => $option ) {
569
+ $checked = ( $value == $i ) ? 'checked="checked"' : '';
570
+ $output .= '<label><input name="'.$field['id'].'" id="'.$field['id'].'" type="radio" value="'.$i.'" '.$checked.' /> '.$option.'</label>'.$break;
571
+ }
572
+ }
573
+
574
+ echo $output;
575
+
576
+ // Add appended fields
577
+ mtphr_dnt_metaboxer_append_field($field);
578
+ }
579
+
580
+
581
+
582
+ /**
583
+ * Renders a select field.
584
+ *
585
+ * @since 1.0.0
586
+ */
587
+ function mtphr_dnt_metaboxer_select( $field, $value='' ) {
588
+
589
+ $before = ( isset($field['before']) ) ? '<span>'.$field['before'].' </span>' : '';
590
+ $after = ( isset($field['after']) ) ? '<span> '.$field['after'].'</span>' : '';
591
+
592
+ $output = $before.'<select name="'.$field['id'].'" id="'.$field['id'].'">';
593
+
594
+ if( $field['options'] ) {
595
+
596
+ $key_val = isset( $field['key_val'] ) ? true : false;
597
+
598
+ foreach ( $field['options'] as $key => $option ) {
599
+ if( is_numeric($key) && !$key_val ) {
600
+ $name = ( is_array( $option ) ) ? $option['name'] : $option;
601
+ $val = ( is_array( $option ) ) ? $option['value'] : $option;
602
+ } else {
603
+ $name = $option;
604
+ $val = $key;
605
+ }
606
+ $selected = ( $val == $value ) ? 'selected="selected"' : '';
607
+ $output .= '<option value="'.$val.'" '.$selected.'>'.stripslashes( $name ).'</option>';
608
+ }
609
+ }
610
+ $output .= '</select>'.$after;
611
+
612
+ echo $output;
613
+
614
+ // Add appended fields
615
+ mtphr_dnt_metaboxer_append_field($field);
616
+ }
617
+
618
+
619
+
620
  /**
621
  * Renders a sort.
622
  *
623
+ * @since 1.0.0
624
  */
625
  function mtphr_dnt_metaboxer_sort( $field, $value='' ) {
626
 
679
  mtphr_dnt_metaboxer_append_field($field);
680
  }
681
 
682
+
 
 
 
 
 
 
 
 
 
 
 
 
683
 
684
  /**
685
+ * Renders an text field.
686
  *
687
+ * @since 1.0.1
688
  */
689
+ function mtphr_dnt_metaboxer_text( $field, $value='' ) {
690
+ $size = ( isset($field['size']) ) ? $field['size'] : 40;
691
+ $before = ( isset($field['before']) ) ? '<span>'.$field['before'].' </span>' : '';
692
+ $after = ( isset($field['after']) ) ? '<span> '.$field['after'].'</span>' : '';
693
+ $text_align = ( isset($field['text_align']) ) ? ' style="text-align:'.$field['text_align'].'"' : '' ;
694
+ $output = $before.'<input name="'.$field['id'].'" id="'.$field['id'].'" type="text" value="'.$value.'" size="'.$size.'"'.$text_align.'>'.$after;
695
+ echo $output;
 
 
 
 
 
 
 
 
 
 
 
 
 
696
 
697
  // Add appended fields
698
  mtphr_dnt_metaboxer_append_field($field);
700
 
701
 
702
 
 
703
  /**
704
+ * Renders a textarea.
705
  *
706
  * @since 1.0.0
707
  */
708
+ function mtphr_dnt_metaboxer_textarea( $field, $value='' ) {
709
+ $rows = ( isset($field['rows']) ) ? $field['rows'] : 5;
710
+ $cols = ( isset($field['cols']) ) ? $field['cols'] : 40;
711
+ $output = '<textarea name="'.$field['id'].'" id="'.$field['id'].'" rows="'.$rows.'" cols="'.$cols.'">'.$value.'</textarea>';
712
+ echo $output;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
713
 
 
 
 
 
 
 
714
  // Add appended fields
715
  mtphr_dnt_metaboxer_append_field($field);
716
  }
717
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
718
 
719
 
720
  /**
721
+ * Renders a wysiwyg field.
722
  *
723
  * @since 1.0.0
724
  */
725
+ function mtphr_dnt_metaboxer_wysiwyg( $field, $value='' ) {
726
+ $settings = array();
727
+ $settings['media_buttons'] = true;
728
+ $settings['textarea_rows'] = ( isset($field['rows']) ) ? $field['rows'] : 12;
729
+ wp_editor( $value, $field['id'], $settings );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
730
 
731
  // Add appended fields
732
  mtphr_dnt_metaboxer_append_field($field);
733
  }
734
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
735
 
736
 
737
 
752
  // Display the function code
753
  } elseif( $field['id'] == '_mtphr_dnt_function' ) {
754
 
755
+ echo '<pre><p>&lt;?php if(function_exists(\'ditty_news_ticker\')){ditty_news_ticker('.$post->ID.');} ?&gt;</p></pre>';
756
  }
757
 
758
  // Display a "Select All" button
includes/widget.php CHANGED
@@ -119,7 +119,7 @@ function update( $new_instance, $old_instance ) {
119
  /**
120
  * Widget settings
121
  *
122
- * @since 1.0
123
  */
124
  function form( $instance ) {
125
 
@@ -143,7 +143,7 @@ function form( $instance ) {
143
  <label for="<?php echo $this->get_field_id( 'ticker' ); ?>"><?php _e( 'Select a Ticker:', 'ditty-news-ticker' ); ?></label><br/>
144
  <select id="<?php echo $this->get_field_id( 'ticker' ); ?>" name="<?php echo $this->get_field_name( 'ticker' ); ?>">
145
  <?php
146
- $tickers = get_posts( 'numberposts=0&post_type=ditty_news_ticker&orderby=name&order=ASC' );
147
  foreach( $tickers as $ticker ) {
148
  if( $instance['ticker'] == $ticker->ID ) {
149
  echo '<option value="'.$ticker->ID.'" selected="selected">'.$ticker->post_title.'</option>';
119
  /**
120
  * Widget settings
121
  *
122
+ * @since 1.0.5
123
  */
124
  function form( $instance ) {
125
 
143
  <label for="<?php echo $this->get_field_id( 'ticker' ); ?>"><?php _e( 'Select a Ticker:', 'ditty-news-ticker' ); ?></label><br/>
144
  <select id="<?php echo $this->get_field_id( 'ticker' ); ?>" name="<?php echo $this->get_field_name( 'ticker' ); ?>">
145
  <?php
146
+ $tickers = get_posts( 'numberposts=-1&post_type=ditty_news_ticker&orderby=name&order=ASC' );
147
  foreach( $tickers as $ticker ) {
148
  if( $instance['ticker'] == $ticker->ID ) {
149
  echo '<option value="'.$ticker->ID.'" selected="selected">'.$ticker->post_title.'</option>';
languages/ditty-news-ticker-en_US.mo CHANGED
Binary file
languages/ditty-news-ticker-en_US.po CHANGED
@@ -1,9 +1,9 @@
1
  msgid ""
2
  msgstr ""
3
- "Project-Id-Version: Ditty News Ticker v1.0.4\n"
4
  "Report-Msgid-Bugs-To: \n"
5
  "POT-Creation-Date: \n"
6
- "PO-Revision-Date: 2013-02-12 20:03:34+0000\n"
7
  "Last-Translator: admin <joe@metaphorcreations.com>\n"
8
  "Language-Team: \n"
9
  "MIME-Version: 1.0\n"
@@ -23,638 +23,633 @@ msgstr ""
23
  #: includes/edit-columns.php:23
24
  #@ ditty-news-ticker
25
  msgid "Type"
26
- msgstr ""
27
 
28
  #: includes/edit-columns.php:24
29
  #@ ditty-news-ticker
30
  msgid "Mode"
31
- msgstr ""
32
 
33
  #: includes/edit-columns.php:25
34
- #: includes/meta-boxes.php:502
35
  #@ ditty-news-ticker
36
  msgid "Shortcode"
37
- msgstr ""
38
 
39
  #: includes/edit-columns.php:26
40
  #@ ditty-news-ticker
41
  msgid "Direct Function"
42
- msgstr ""
43
 
44
  #: includes/functions.php:342
45
  #@ ditty-news-ticker
46
  msgid "Default"
47
- msgstr ""
48
 
49
  #: includes/functions.php:362
50
  #@ ditty-news-ticker
51
  msgid "Scroll"
52
- msgstr ""
53
 
54
  #: includes/functions.php:366
55
  #@ ditty-news-ticker
56
  msgid "Rotate"
57
- msgstr ""
58
 
59
  #: includes/functions.php:370
60
  #@ ditty-news-ticker
61
  msgid "List"
62
- msgstr ""
63
 
64
  #: includes/help.php:59
65
  #@ ditty-news-ticker
66
  msgid "Scroll Mode"
67
- msgstr ""
68
 
69
  #: includes/help.php:66
70
  #@ ditty-news-ticker
71
  msgid "Rotate Mode"
72
- msgstr ""
73
 
74
  #: includes/help.php:73
75
  #@ ditty-news-ticker
76
  msgid "List Mode"
77
- msgstr ""
78
 
79
  #: includes/help.php:95
80
  #: includes/widget.php:51
81
  #@ ditty-news-ticker
82
  msgid "Ditty News Ticker"
83
- msgstr ""
84
 
85
  #: includes/help.php:110
86
  #@ ditty-news-ticker
87
  msgid "For more information:"
88
- msgstr ""
89
 
90
  #: includes/help.php:111
91
  #@ ditty-news-ticker
92
  msgid "Visit the <a href=\"http://www.metaphorcreations.com\" target=\"_blank\">documentation</a> on the Ditty News Ticker website"
93
- msgstr ""
94
-
95
- #: includes/help.php:112
96
- #@ ditty-news-ticker
97
- msgid "<strong><a href=\"http://www.metaphorcreations.com\" target=\"_blnak\">View DNT extensions"
98
- msgstr ""
99
 
100
  #: includes/help.php:126
101
  #@ ditty-news-ticker
102
  msgid "Add general information about Ditty News Ticker."
103
- msgstr ""
104
 
105
  #: includes/help.php:135
106
  #@ ditty-news-ticker
107
  msgid "Add scroll mode info."
108
- msgstr ""
109
 
110
  #: includes/help.php:144
111
  #@ ditty-news-ticker
112
  msgid "Add rotate mode info."
113
- msgstr ""
114
 
115
  #: includes/help.php:153
116
  #@ ditty-news-ticker
117
  msgid "Add list mode info."
118
- msgstr ""
119
 
120
  #: includes/meta-boxes.php:22
121
  #@ ditty-news-ticker
122
  msgid "Ticker Type"
123
- msgstr ""
124
 
125
  #: includes/meta-boxes.php:35
126
  #@ ditty-news-ticker
127
  msgid "View all types"
128
- msgstr ""
129
 
130
  #: includes/meta-boxes.php:58
131
  #@ ditty-news-ticker
132
  msgid "Ticker text"
133
- msgstr ""
134
 
135
  #: includes/meta-boxes.php:64
136
  #@ ditty-news-ticker
137
  msgid "Link"
138
- msgstr ""
139
 
140
  #: includes/meta-boxes.php:68
141
  #@ ditty-news-ticker
142
  msgid "Target"
143
- msgstr ""
144
 
145
  #: includes/meta-boxes.php:87
146
  #@ ditty-news-ticker
147
  msgid "Default Ticker Items"
148
- msgstr ""
149
-
150
- #: includes/meta-boxes.php:119
151
- #@ ditty-news-ticker
152
- msgid "View all modes"
153
- msgstr ""
154
 
155
- #: includes/meta-boxes.php:127
156
  #@ ditty-news-ticker
157
  msgid "Ticker Mode"
158
- msgstr ""
159
 
160
- #: includes/meta-boxes.php:154
161
  #@ ditty-news-ticker
162
  msgid "Scroll direction"
163
- msgstr ""
164
 
165
- #: includes/meta-boxes.php:156
166
  #@ ditty-news-ticker
167
  msgid "Left"
168
- msgstr ""
169
 
170
- #: includes/meta-boxes.php:157
171
  #@ ditty-news-ticker
172
  msgid "Right"
173
- msgstr ""
174
 
175
- #: includes/meta-boxes.php:158
176
  #@ ditty-news-ticker
177
  msgid "Up"
178
- msgstr ""
179
 
180
- #: includes/meta-boxes.php:159
181
  #@ ditty-news-ticker
182
  msgid "Down"
183
- msgstr ""
184
 
185
- #: includes/meta-boxes.php:162
186
  #@ ditty-news-ticker
187
  msgid "Set the scroll direction of the ticker."
188
- msgstr ""
189
 
190
- #: includes/meta-boxes.php:170
191
- #: includes/meta-boxes.php:278
192
  #@ ditty-news-ticker
193
  msgid "Tick dimensions"
194
- msgstr ""
195
 
196
- #: includes/meta-boxes.php:172
197
  #@ ditty-news-ticker
198
  msgid "Width"
199
- msgstr ""
200
 
201
- #: includes/meta-boxes.php:173
202
- #: includes/meta-boxes.php:281
203
  #@ ditty-news-ticker
204
  msgid "Override the auto dimensions with specific values."
205
- msgstr ""
206
 
207
- #: includes/meta-boxes.php:178
208
- #: includes/meta-boxes.php:280
209
  #@ ditty-news-ticker
210
  msgid "Height"
211
- msgstr ""
212
 
213
- #: includes/meta-boxes.php:187
214
  #@ ditty-news-ticker
215
  msgid "Scroller padding"
216
- msgstr ""
217
 
218
- #: includes/meta-boxes.php:189
219
- #: includes/meta-boxes.php:290
220
- #: includes/meta-boxes.php:404
221
  #@ ditty-news-ticker
222
  msgid "Vertical padding"
223
- msgstr ""
224
 
225
- #: includes/meta-boxes.php:190
226
  #@ ditty-news-ticker
227
  msgid "Set the vertical spacing of the scrolling data."
228
- msgstr ""
229
 
230
- #: includes/meta-boxes.php:195
231
- #: includes/meta-boxes.php:296
232
- #: includes/meta-boxes.php:410
233
  #@ ditty-news-ticker
234
  msgid "Vertical margin"
235
- msgstr ""
236
 
237
- #: includes/meta-boxes.php:204
238
  #@ ditty-news-ticker
239
  msgid "Scroll speed"
240
- msgstr ""
241
 
242
- #: includes/meta-boxes.php:206
243
  #@ ditty-news-ticker
244
  msgid "Set the speed of the scrolling data."
245
- msgstr ""
246
 
247
- #: includes/meta-boxes.php:210
248
- #: includes/meta-boxes.php:316
249
  #@ ditty-news-ticker
250
  msgid "Pause on mouse over"
251
- msgstr ""
252
 
253
- #: includes/meta-boxes.php:219
254
- #: includes/meta-boxes.php:419
255
  #@ ditty-news-ticker
256
  msgid "Tick spacing"
257
- msgstr ""
258
 
259
- #: includes/meta-boxes.php:221
260
- #: includes/meta-boxes.php:421
261
  #@ ditty-news-ticker
262
  msgid "Pixels"
263
- msgstr ""
264
 
265
- #: includes/meta-boxes.php:222
266
  #@ ditty-news-ticker
267
  msgid "Set the spacing between scrolling data."
268
- msgstr ""
269
 
270
- #: includes/meta-boxes.php:228
271
  #@ ditty-news-ticker
272
  msgid "Scroll Settings"
273
- msgstr ""
274
 
275
- #: includes/meta-boxes.php:255
276
  #@ ditty-news-ticker
277
  msgid "Rotation type"
278
- msgstr ""
279
 
280
- #: includes/meta-boxes.php:257
281
  #@ ditty-news-ticker
282
  msgid "Fade"
283
- msgstr ""
284
 
285
- #: includes/meta-boxes.php:258
286
  #@ ditty-news-ticker
287
  msgid "Slide left"
288
- msgstr ""
289
 
290
- #: includes/meta-boxes.php:259
291
  #@ ditty-news-ticker
292
  msgid "Slide right"
293
- msgstr ""
294
 
295
- #: includes/meta-boxes.php:260
296
  #@ ditty-news-ticker
297
  msgid "Slide up"
298
- msgstr ""
299
 
300
- #: includes/meta-boxes.php:261
301
  #@ ditty-news-ticker
302
  msgid "Slide down"
303
- msgstr ""
304
 
305
- #: includes/meta-boxes.php:264
306
  #@ ditty-news-ticker
307
  msgid "Set the type of rotation for the ticker."
308
- msgstr ""
309
 
310
- #: includes/meta-boxes.php:269
311
  #@ ditty-news-ticker
312
  msgid "Dynamic slide direction"
313
- msgstr ""
314
 
315
- #: includes/meta-boxes.php:288
316
  #@ ditty-news-ticker
317
  msgid "Rotator padding"
318
- msgstr ""
319
 
320
- #: includes/meta-boxes.php:291
321
  #@ ditty-news-ticker
322
  msgid "Set the vertical spacing of the rotating data."
323
- msgstr ""
324
 
325
- #: includes/meta-boxes.php:305
326
  #@ ditty-news-ticker
327
  msgid "Auto rotate"
328
- msgstr ""
329
 
330
- #: includes/meta-boxes.php:306
331
- #: includes/meta-boxes.php:342
332
- #: includes/meta-boxes.php:357
333
  #@ ditty-news-ticker
334
  msgid "Enable"
335
- msgstr ""
336
 
337
- #: includes/meta-boxes.php:307
338
  #@ ditty-news-ticker
339
  msgid "Set the delay between rotations."
340
- msgstr ""
341
 
342
- #: includes/meta-boxes.php:312
343
  #@ ditty-news-ticker
344
  msgid "Seconds delay"
345
- msgstr ""
346
 
347
- #: includes/meta-boxes.php:325
348
  #@ ditty-news-ticker
349
  msgid "Rotate speed"
350
- msgstr ""
351
 
352
- #: includes/meta-boxes.php:327
353
  #@ ditty-news-ticker
354
  msgid "Tenths of a second"
355
- msgstr ""
356
 
357
- #: includes/meta-boxes.php:328
358
  #@ ditty-news-ticker
359
  msgid "Set the speed & easing of the rotation."
360
- msgstr ""
361
 
362
- #: includes/meta-boxes.php:341
363
  #@ ditty-news-ticker
364
  msgid "Directional navigation"
365
- msgstr ""
366
 
367
- #: includes/meta-boxes.php:343
368
  #@ ditty-news-ticker
369
  msgid "Set the directional navigation options."
370
- msgstr ""
371
 
372
- #: includes/meta-boxes.php:347
373
  #@ ditty-news-ticker
374
  msgid "Autohide navigation"
375
- msgstr ""
376
 
377
- #: includes/meta-boxes.php:356
378
  #@ ditty-news-ticker
379
  msgid "Control navigation"
380
- msgstr ""
381
 
382
- #: includes/meta-boxes.php:358
383
  #@ ditty-news-ticker
384
  msgid "Set the control navigation options."
385
- msgstr ""
386
 
387
- #: includes/meta-boxes.php:363
388
  #@ ditty-news-ticker
389
  msgid "Numbers"
390
- msgstr ""
391
 
392
- #: includes/meta-boxes.php:364
393
  #@ ditty-news-ticker
394
  msgid "Buttons"
395
- msgstr ""
396
 
397
- #: includes/meta-boxes.php:375
398
  #@ ditty-news-ticker
399
  msgid "Rotate Settings"
400
- msgstr ""
401
 
402
- #: includes/meta-boxes.php:402
403
  #@ ditty-news-ticker
404
  msgid "List padding"
405
- msgstr ""
406
 
407
- #: includes/meta-boxes.php:405
408
  #@ ditty-news-ticker
409
  msgid "Set the vertical spacing of the list container."
410
- msgstr ""
411
 
412
- #: includes/meta-boxes.php:422
413
  #@ ditty-news-ticker
414
  msgid "Set the spacing between ticks."
415
- msgstr ""
416
 
417
- #: includes/meta-boxes.php:428
418
  #@ ditty-news-ticker
419
  msgid "List Settings"
420
- msgstr ""
421
 
422
- #: includes/meta-boxes.php:455
423
  #@ ditty-news-ticker
424
  msgid "Display title"
425
- msgstr ""
426
 
427
- #: includes/meta-boxes.php:459
428
  #@ ditty-news-ticker
429
  msgid "Inline title"
430
- msgstr ""
431
 
432
- #: includes/meta-boxes.php:467
433
  #@ ditty-news-ticker
434
  msgid "Ticker width <em>(optional)</em>"
435
- msgstr ""
436
 
437
- #: includes/meta-boxes.php:469
438
  #@ ditty-news-ticker
439
  msgid "Override the auto width a with specific value."
440
- msgstr ""
441
 
442
- #: includes/meta-boxes.php:475
443
  #@ ditty-news-ticker
444
  msgid "Global Settings"
445
- msgstr ""
446
 
447
- #: includes/meta-boxes.php:503
448
  #@ ditty-news-ticker
449
  msgid "Select Shortcode"
450
- msgstr ""
451
 
452
- #: includes/meta-boxes.php:504
453
  #@ ditty-news-ticker
454
  msgid "Use this shortcode to insert the ticker into a post/page."
455
- msgstr ""
456
 
457
- #: includes/meta-boxes.php:511
458
  #@ ditty-news-ticker
459
  msgid "Direct function"
460
- msgstr ""
461
 
462
- #: includes/meta-boxes.php:512
463
  #@ ditty-news-ticker
464
  msgid "Select Function"
465
- msgstr ""
466
 
467
- #: includes/meta-boxes.php:513
468
  #@ ditty-news-ticker
469
  msgid "Place this code directly into your theme to display the ticker."
470
- msgstr ""
471
 
472
- #: includes/meta-boxes.php:519
473
  #@ ditty-news-ticker
474
  msgid "Ticker Display"
475
- msgstr ""
476
 
477
- #: includes/metaboxer/metaboxer.php:943
478
  #@ ditty-news-ticker
479
  msgid "Select Code"
480
- msgstr ""
481
 
482
  #: includes/post-types.php:20
483
  #: includes/post-types.php:31
484
  #@ ditty-news-ticker
485
  msgid "News Tickers"
486
- msgstr ""
487
 
488
  #: includes/post-types.php:21
489
  #@ ditty-news-ticker
490
  msgid "News Ticker"
491
- msgstr ""
492
 
493
  #: includes/post-types.php:22
494
  #@ ditty-news-ticker
495
  msgid "Add New"
496
- msgstr ""
497
 
498
  #: includes/post-types.php:23
499
  #@ ditty-news-ticker
500
  msgid "Add New News Ticker"
501
- msgstr ""
502
 
503
  #: includes/post-types.php:24
504
  #@ ditty-news-ticker
505
  msgid "Edit News Ticker"
506
- msgstr ""
507
 
508
  #: includes/post-types.php:25
509
  #@ ditty-news-ticker
510
  msgid "New News Ticker"
511
- msgstr ""
512
 
513
  #: includes/post-types.php:26
514
  #@ ditty-news-ticker
515
  msgid "View News Ticker"
516
- msgstr ""
517
 
518
  #: includes/post-types.php:27
519
  #@ ditty-news-ticker
520
  msgid "Search News Tickers"
521
- msgstr ""
522
 
523
  #: includes/post-types.php:28
524
  #@ ditty-news-ticker
525
  msgid "No News Tickers Found"
526
- msgstr ""
527
 
528
  #: includes/post-types.php:29
529
  #@ ditty-news-ticker
530
  msgid "No News Tickers Found In Trash"
531
- msgstr ""
532
 
533
  #: includes/post-types.php:62
534
  #@ ditty-news-ticker
535
  msgid "Ditty News Ticker Updated!"
536
- msgstr ""
537
 
538
  #: includes/settings.php:21
539
  #: includes/settings.php:22
540
  #@ ditty-news-ticker
541
  msgid "Settings"
542
- msgstr ""
543
 
544
  #: includes/settings.php:46
545
  #@ ditty-news-ticker
546
  msgid "Custom CSS"
547
- msgstr ""
548
 
549
  #: includes/settings.php:49
550
  #@ ditty-news-ticker
551
  msgid "Custom CSS will be added to the head of each page that includes a Ditty News Ticker."
552
- msgstr ""
553
 
554
  #: includes/settings.php:58
555
  #: includes/settings.php:95
556
  #@ ditty-news-ticker
557
  msgid "&nbsp;"
558
- msgstr ""
559
 
560
  #: includes/settings.php:130
561
  #@ ditty-news-ticker
562
  msgid "Ditty News Ticker Settings"
563
- msgstr ""
564
 
565
  #: includes/settings.php:144
566
  #@ ditty-news-ticker
567
  msgid "General"
568
- msgstr ""
569
 
570
  #: includes/settings.php:145
571
  #@ ditty-news-ticker
572
  msgid "Extension Licenses"
573
- msgstr ""
574
 
575
  #: includes/settings.php:178
576
  #@ ditty-news-ticker
577
  msgid "Add global settings to your news tickers."
578
- msgstr ""
579
 
580
  #: includes/settings.php:179
581
  #@ ditty-news-ticker
582
  msgid "Use the Custom CSS textarea to set global or individual styles to each of your tickers."
583
- msgstr ""
584
 
585
  #: includes/settings.php:188
586
  #@ ditty-news-ticker
587
  msgid "Add the licenses for each of your extensions."
588
- msgstr ""
589
 
590
  #: includes/taxonomies.php:21
591
  #: includes/taxonomies.php:31
592
  #@ ditty-news-ticker
593
  msgid "Categories"
594
- msgstr ""
595
 
596
  #: includes/taxonomies.php:22
597
  #@ ditty-news-ticker
598
  msgid "Category"
599
- msgstr ""
600
 
601
  #: includes/taxonomies.php:23
602
  #@ ditty-news-ticker
603
  msgid "Search Categories"
604
- msgstr ""
605
 
606
  #: includes/taxonomies.php:24
607
  #@ ditty-news-ticker
608
  msgid "All Categories"
609
- msgstr ""
610
 
611
  #: includes/taxonomies.php:25
612
  #@ ditty-news-ticker
613
  msgid "Parent"
614
- msgstr ""
615
 
616
  #: includes/taxonomies.php:26
617
  #@ ditty-news-ticker
618
  msgid "Parent:"
619
- msgstr ""
620
 
621
  #: includes/taxonomies.php:27
622
  #@ ditty-news-ticker
623
  msgid "Edit Category"
624
- msgstr ""
625
 
626
  #: includes/taxonomies.php:28
627
  #@ ditty-news-ticker
628
  msgid "Update Category"
629
- msgstr ""
630
 
631
  #: includes/taxonomies.php:29
632
  #@ ditty-news-ticker
633
  msgid "Add New Category"
634
- msgstr ""
635
 
636
  #: includes/taxonomies.php:30
637
  #@ ditty-news-ticker
638
  msgid "New Category"
639
- msgstr ""
640
 
641
  #: includes/widget.php:42
642
  #@ ditty-news-ticker
643
  msgid "Displays a Ditty News Ticker."
644
- msgstr ""
645
 
646
- #: includes/widget.php:134
647
  #@ ditty-news-ticker
648
  msgid "Title:"
649
- msgstr ""
650
 
651
- #: includes/widget.php:140
652
  #@ ditty-news-ticker
653
  msgid "Select a Ticker:"
654
- msgstr ""
655
 
656
- #: includes/widget.php:158
657
  #@ ditty-news-ticker
658
  msgid "Display Ticker Title?"
659
- msgstr ""
 
 
 
 
 
660
 
1
  msgid ""
2
  msgstr ""
3
+ "Project-Id-Version: Ditty News Ticker v1.0.5\n"
4
  "Report-Msgid-Bugs-To: \n"
5
  "POT-Creation-Date: \n"
6
+ "PO-Revision-Date: 2013-02-26 01:54:01+0000\n"
7
  "Last-Translator: admin <joe@metaphorcreations.com>\n"
8
  "Language-Team: \n"
9
  "MIME-Version: 1.0\n"
23
  #: includes/edit-columns.php:23
24
  #@ ditty-news-ticker
25
  msgid "Type"
26
+ msgstr "Type"
27
 
28
  #: includes/edit-columns.php:24
29
  #@ ditty-news-ticker
30
  msgid "Mode"
31
+ msgstr "Mode"
32
 
33
  #: includes/edit-columns.php:25
34
+ #: includes/meta-boxes.php:496
35
  #@ ditty-news-ticker
36
  msgid "Shortcode"
37
+ msgstr "Shortcode"
38
 
39
  #: includes/edit-columns.php:26
40
  #@ ditty-news-ticker
41
  msgid "Direct Function"
42
+ msgstr "Direct Function"
43
 
44
  #: includes/functions.php:342
45
  #@ ditty-news-ticker
46
  msgid "Default"
47
+ msgstr "Default"
48
 
49
  #: includes/functions.php:362
50
  #@ ditty-news-ticker
51
  msgid "Scroll"
52
+ msgstr "Scroll"
53
 
54
  #: includes/functions.php:366
55
  #@ ditty-news-ticker
56
  msgid "Rotate"
57
+ msgstr "Rotate"
58
 
59
  #: includes/functions.php:370
60
  #@ ditty-news-ticker
61
  msgid "List"
62
+ msgstr "List"
63
 
64
  #: includes/help.php:59
65
  #@ ditty-news-ticker
66
  msgid "Scroll Mode"
67
+ msgstr "Scroll Mode"
68
 
69
  #: includes/help.php:66
70
  #@ ditty-news-ticker
71
  msgid "Rotate Mode"
72
+ msgstr "Rotate Mode"
73
 
74
  #: includes/help.php:73
75
  #@ ditty-news-ticker
76
  msgid "List Mode"
77
+ msgstr "List Mode"
78
 
79
  #: includes/help.php:95
80
  #: includes/widget.php:51
81
  #@ ditty-news-ticker
82
  msgid "Ditty News Ticker"
83
+ msgstr "Ditty News Ticker"
84
 
85
  #: includes/help.php:110
86
  #@ ditty-news-ticker
87
  msgid "For more information:"
88
+ msgstr "For more information:"
89
 
90
  #: includes/help.php:111
91
  #@ ditty-news-ticker
92
  msgid "Visit the <a href=\"http://www.metaphorcreations.com\" target=\"_blank\">documentation</a> on the Ditty News Ticker website"
93
+ msgstr "Visit the <a href=\"http://www.metaphorcreations.com\" target=\"_blank\">documentation</a> on the Ditty News Ticker website"
 
 
 
 
 
94
 
95
  #: includes/help.php:126
96
  #@ ditty-news-ticker
97
  msgid "Add general information about Ditty News Ticker."
98
+ msgstr "Add general information about Ditty News Ticker."
99
 
100
  #: includes/help.php:135
101
  #@ ditty-news-ticker
102
  msgid "Add scroll mode info."
103
+ msgstr "Add scroll mode info."
104
 
105
  #: includes/help.php:144
106
  #@ ditty-news-ticker
107
  msgid "Add rotate mode info."
108
+ msgstr "Add rotate mode info."
109
 
110
  #: includes/help.php:153
111
  #@ ditty-news-ticker
112
  msgid "Add list mode info."
113
+ msgstr "Add list mode info."
114
 
115
  #: includes/meta-boxes.php:22
116
  #@ ditty-news-ticker
117
  msgid "Ticker Type"
118
+ msgstr "Ticker Type"
119
 
120
  #: includes/meta-boxes.php:35
121
  #@ ditty-news-ticker
122
  msgid "View all types"
123
+ msgstr "View all types"
124
 
125
  #: includes/meta-boxes.php:58
126
  #@ ditty-news-ticker
127
  msgid "Ticker text"
128
+ msgstr "Ticker text"
129
 
130
  #: includes/meta-boxes.php:64
131
  #@ ditty-news-ticker
132
  msgid "Link"
133
+ msgstr "Link"
134
 
135
  #: includes/meta-boxes.php:68
136
  #@ ditty-news-ticker
137
  msgid "Target"
138
+ msgstr "Target"
139
 
140
  #: includes/meta-boxes.php:87
141
  #@ ditty-news-ticker
142
  msgid "Default Ticker Items"
143
+ msgstr "Default Ticker Items"
 
 
 
 
 
144
 
145
+ #: includes/meta-boxes.php:121
146
  #@ ditty-news-ticker
147
  msgid "Ticker Mode"
148
+ msgstr "Ticker Mode"
149
 
150
+ #: includes/meta-boxes.php:148
151
  #@ ditty-news-ticker
152
  msgid "Scroll direction"
153
+ msgstr "Scroll direction"
154
 
155
+ #: includes/meta-boxes.php:150
156
  #@ ditty-news-ticker
157
  msgid "Left"
158
+ msgstr "Left"
159
 
160
+ #: includes/meta-boxes.php:151
161
  #@ ditty-news-ticker
162
  msgid "Right"
163
+ msgstr "Right"
164
 
165
+ #: includes/meta-boxes.php:152
166
  #@ ditty-news-ticker
167
  msgid "Up"
168
+ msgstr "Up"
169
 
170
+ #: includes/meta-boxes.php:153
171
  #@ ditty-news-ticker
172
  msgid "Down"
173
+ msgstr "Down"
174
 
175
+ #: includes/meta-boxes.php:156
176
  #@ ditty-news-ticker
177
  msgid "Set the scroll direction of the ticker."
178
+ msgstr "Set the scroll direction of the ticker."
179
 
180
+ #: includes/meta-boxes.php:164
181
+ #: includes/meta-boxes.php:272
182
  #@ ditty-news-ticker
183
  msgid "Tick dimensions"
184
+ msgstr "Tick dimensions"
185
 
186
+ #: includes/meta-boxes.php:166
187
  #@ ditty-news-ticker
188
  msgid "Width"
189
+ msgstr "Width"
190
 
191
+ #: includes/meta-boxes.php:167
192
+ #: includes/meta-boxes.php:275
193
  #@ ditty-news-ticker
194
  msgid "Override the auto dimensions with specific values."
195
+ msgstr "Override the auto dimensions with specific values."
196
 
197
+ #: includes/meta-boxes.php:172
198
+ #: includes/meta-boxes.php:274
199
  #@ ditty-news-ticker
200
  msgid "Height"
201
+ msgstr "Height"
202
 
203
+ #: includes/meta-boxes.php:181
204
  #@ ditty-news-ticker
205
  msgid "Scroller padding"
206
+ msgstr "Scroller padding"
207
 
208
+ #: includes/meta-boxes.php:183
209
+ #: includes/meta-boxes.php:284
210
+ #: includes/meta-boxes.php:398
211
  #@ ditty-news-ticker
212
  msgid "Vertical padding"
213
+ msgstr "Vertical padding"
214
 
215
+ #: includes/meta-boxes.php:184
216
  #@ ditty-news-ticker
217
  msgid "Set the vertical spacing of the scrolling data."
218
+ msgstr "Set the vertical spacing of the scrolling data."
219
 
220
+ #: includes/meta-boxes.php:189
221
+ #: includes/meta-boxes.php:290
222
+ #: includes/meta-boxes.php:404
223
  #@ ditty-news-ticker
224
  msgid "Vertical margin"
225
+ msgstr "Vertical margin"
226
 
227
+ #: includes/meta-boxes.php:198
228
  #@ ditty-news-ticker
229
  msgid "Scroll speed"
230
+ msgstr "Scroll speed"
231
 
232
+ #: includes/meta-boxes.php:200
233
  #@ ditty-news-ticker
234
  msgid "Set the speed of the scrolling data."
235
+ msgstr "Set the speed of the scrolling data."
236
 
237
+ #: includes/meta-boxes.php:204
238
+ #: includes/meta-boxes.php:310
239
  #@ ditty-news-ticker
240
  msgid "Pause on mouse over"
241
+ msgstr "Pause on mouse over"
242
 
243
+ #: includes/meta-boxes.php:213
244
+ #: includes/meta-boxes.php:413
245
  #@ ditty-news-ticker
246
  msgid "Tick spacing"
247
+ msgstr "Tick spacing"
248
 
249
+ #: includes/meta-boxes.php:215
250
+ #: includes/meta-boxes.php:415
251
  #@ ditty-news-ticker
252
  msgid "Pixels"
253
+ msgstr "Pixels"
254
 
255
+ #: includes/meta-boxes.php:216
256
  #@ ditty-news-ticker
257
  msgid "Set the spacing between scrolling data."
258
+ msgstr "Set the spacing between scrolling data."
259
 
260
+ #: includes/meta-boxes.php:222
261
  #@ ditty-news-ticker
262
  msgid "Scroll Settings"
263
+ msgstr "Scroll Settings"
264
 
265
+ #: includes/meta-boxes.php:249
266
  #@ ditty-news-ticker
267
  msgid "Rotation type"
268
+ msgstr "Rotation type"
269
 
270
+ #: includes/meta-boxes.php:251
271
  #@ ditty-news-ticker
272
  msgid "Fade"
273
+ msgstr "Fade"
274
 
275
+ #: includes/meta-boxes.php:252
276
  #@ ditty-news-ticker
277
  msgid "Slide left"
278
+ msgstr "Slide left"
279
 
280
+ #: includes/meta-boxes.php:253
281
  #@ ditty-news-ticker
282
  msgid "Slide right"
283
+ msgstr "Slide right"
284
 
285
+ #: includes/meta-boxes.php:254
286
  #@ ditty-news-ticker
287
  msgid "Slide up"
288
+ msgstr "Slide up"
289
 
290
+ #: includes/meta-boxes.php:255
291
  #@ ditty-news-ticker
292
  msgid "Slide down"
293
+ msgstr "Slide down"
294
 
295
+ #: includes/meta-boxes.php:258
296
  #@ ditty-news-ticker
297
  msgid "Set the type of rotation for the ticker."
298
+ msgstr "Set the type of rotation for the ticker."
299
 
300
+ #: includes/meta-boxes.php:263
301
  #@ ditty-news-ticker
302
  msgid "Dynamic slide direction"
303
+ msgstr "Dynamic slide direction"
304
 
305
+ #: includes/meta-boxes.php:282
306
  #@ ditty-news-ticker
307
  msgid "Rotator padding"
308
+ msgstr "Rotator padding"
309
 
310
+ #: includes/meta-boxes.php:285
311
  #@ ditty-news-ticker
312
  msgid "Set the vertical spacing of the rotating data."
313
+ msgstr "Set the vertical spacing of the rotating data."
314
 
315
+ #: includes/meta-boxes.php:299
316
  #@ ditty-news-ticker
317
  msgid "Auto rotate"
318
+ msgstr "Auto rotate"
319
 
320
+ #: includes/meta-boxes.php:300
321
+ #: includes/meta-boxes.php:336
322
+ #: includes/meta-boxes.php:351
323
  #@ ditty-news-ticker
324
  msgid "Enable"
325
+ msgstr "Enable"
326
 
327
+ #: includes/meta-boxes.php:301
328
  #@ ditty-news-ticker
329
  msgid "Set the delay between rotations."
330
+ msgstr "Set the delay between rotations."
331
 
332
+ #: includes/meta-boxes.php:306
333
  #@ ditty-news-ticker
334
  msgid "Seconds delay"
335
+ msgstr "Seconds delay"
336
 
337
+ #: includes/meta-boxes.php:319
338
  #@ ditty-news-ticker
339
  msgid "Rotate speed"
340
+ msgstr "Rotate speed"
341
 
342
+ #: includes/meta-boxes.php:321
343
  #@ ditty-news-ticker
344
  msgid "Tenths of a second"
345
+ msgstr "Tenths of a second"
346
 
347
+ #: includes/meta-boxes.php:322
348
  #@ ditty-news-ticker
349
  msgid "Set the speed & easing of the rotation."
350
+ msgstr "Set the speed & easing of the rotation."
351
 
352
+ #: includes/meta-boxes.php:335
353
  #@ ditty-news-ticker
354
  msgid "Directional navigation"
355
+ msgstr "Directional navigation"
356
 
357
+ #: includes/meta-boxes.php:337
358
  #@ ditty-news-ticker
359
  msgid "Set the directional navigation options."
360
+ msgstr "Set the directional navigation options."
361
 
362
+ #: includes/meta-boxes.php:341
363
  #@ ditty-news-ticker
364
  msgid "Autohide navigation"
365
+ msgstr "Autohide navigation"
366
 
367
+ #: includes/meta-boxes.php:350
368
  #@ ditty-news-ticker
369
  msgid "Control navigation"
370
+ msgstr "Control navigation"
371
 
372
+ #: includes/meta-boxes.php:352
373
  #@ ditty-news-ticker
374
  msgid "Set the control navigation options."
375
+ msgstr "Set the control navigation options."
376
 
377
+ #: includes/meta-boxes.php:357
378
  #@ ditty-news-ticker
379
  msgid "Numbers"
380
+ msgstr "Numbers"
381
 
382
+ #: includes/meta-boxes.php:358
383
  #@ ditty-news-ticker
384
  msgid "Buttons"
385
+ msgstr "Buttons"
386
 
387
+ #: includes/meta-boxes.php:369
388
  #@ ditty-news-ticker
389
  msgid "Rotate Settings"
390
+ msgstr "Rotate Settings"
391
 
392
+ #: includes/meta-boxes.php:396
393
  #@ ditty-news-ticker
394
  msgid "List padding"
395
+ msgstr "List padding"
396
 
397
+ #: includes/meta-boxes.php:399
398
  #@ ditty-news-ticker
399
  msgid "Set the vertical spacing of the list container."
400
+ msgstr "Set the vertical spacing of the list container."
401
 
402
+ #: includes/meta-boxes.php:416
403
  #@ ditty-news-ticker
404
  msgid "Set the spacing between ticks."
405
+ msgstr "Set the spacing between ticks."
406
 
407
+ #: includes/meta-boxes.php:422
408
  #@ ditty-news-ticker
409
  msgid "List Settings"
410
+ msgstr "List Settings"
411
 
412
+ #: includes/meta-boxes.php:449
413
  #@ ditty-news-ticker
414
  msgid "Display title"
415
+ msgstr "Display title"
416
 
417
+ #: includes/meta-boxes.php:453
418
  #@ ditty-news-ticker
419
  msgid "Inline title"
420
+ msgstr "Inline title"
421
 
422
+ #: includes/meta-boxes.php:461
423
  #@ ditty-news-ticker
424
  msgid "Ticker width <em>(optional)</em>"
425
+ msgstr "Ticker width <em>(optional)</em>"
426
 
427
+ #: includes/meta-boxes.php:463
428
  #@ ditty-news-ticker
429
  msgid "Override the auto width a with specific value."
430
+ msgstr "Override the auto width a with specific value."
431
 
432
+ #: includes/meta-boxes.php:469
433
  #@ ditty-news-ticker
434
  msgid "Global Settings"
435
+ msgstr "Global Settings"
436
 
437
+ #: includes/meta-boxes.php:497
438
  #@ ditty-news-ticker
439
  msgid "Select Shortcode"
440
+ msgstr "Select Shortcode"
441
 
442
+ #: includes/meta-boxes.php:498
443
  #@ ditty-news-ticker
444
  msgid "Use this shortcode to insert the ticker into a post/page."
445
+ msgstr "Use this shortcode to insert the ticker into a post/page."
446
 
447
+ #: includes/meta-boxes.php:505
448
  #@ ditty-news-ticker
449
  msgid "Direct function"
450
+ msgstr "Direct function"
451
 
452
+ #: includes/meta-boxes.php:506
453
  #@ ditty-news-ticker
454
  msgid "Select Function"
455
+ msgstr "Select Function"
456
 
457
+ #: includes/meta-boxes.php:507
458
  #@ ditty-news-ticker
459
  msgid "Place this code directly into your theme to display the ticker."
460
+ msgstr "Place this code directly into your theme to display the ticker."
461
 
462
+ #: includes/meta-boxes.php:513
463
  #@ ditty-news-ticker
464
  msgid "Ticker Display"
465
+ msgstr "Ticker Display"
466
 
467
+ #: includes/metaboxer/metaboxer.php:759
468
  #@ ditty-news-ticker
469
  msgid "Select Code"
470
+ msgstr "Select Code"
471
 
472
  #: includes/post-types.php:20
473
  #: includes/post-types.php:31
474
  #@ ditty-news-ticker
475
  msgid "News Tickers"
476
+ msgstr "News Tickers"
477
 
478
  #: includes/post-types.php:21
479
  #@ ditty-news-ticker
480
  msgid "News Ticker"
481
+ msgstr "News Ticker"
482
 
483
  #: includes/post-types.php:22
484
  #@ ditty-news-ticker
485
  msgid "Add New"
486
+ msgstr "Add New"
487
 
488
  #: includes/post-types.php:23
489
  #@ ditty-news-ticker
490
  msgid "Add New News Ticker"
491
+ msgstr "Add New News Ticker"
492
 
493
  #: includes/post-types.php:24
494
  #@ ditty-news-ticker
495
  msgid "Edit News Ticker"
496
+ msgstr "Edit News Ticker"
497
 
498
  #: includes/post-types.php:25
499
  #@ ditty-news-ticker
500
  msgid "New News Ticker"
501
+ msgstr "New News Ticker"
502
 
503
  #: includes/post-types.php:26
504
  #@ ditty-news-ticker
505
  msgid "View News Ticker"
506
+ msgstr "View News Ticker"
507
 
508
  #: includes/post-types.php:27
509
  #@ ditty-news-ticker
510
  msgid "Search News Tickers"
511
+ msgstr "Search News Tickers"
512
 
513
  #: includes/post-types.php:28
514
  #@ ditty-news-ticker
515
  msgid "No News Tickers Found"
516
+ msgstr "No News Tickers Found"
517
 
518
  #: includes/post-types.php:29
519
  #@ ditty-news-ticker
520
  msgid "No News Tickers Found In Trash"
521
+ msgstr "No News Tickers Found In Trash"
522
 
523
  #: includes/post-types.php:62
524
  #@ ditty-news-ticker
525
  msgid "Ditty News Ticker Updated!"
526
+ msgstr "Ditty News Ticker Updated!"
527
 
528
  #: includes/settings.php:21
529
  #: includes/settings.php:22
530
  #@ ditty-news-ticker
531
  msgid "Settings"
532
+ msgstr "Settings"
533
 
534
  #: includes/settings.php:46
535
  #@ ditty-news-ticker
536
  msgid "Custom CSS"
537
+ msgstr "Custom CSS"
538
 
539
  #: includes/settings.php:49
540
  #@ ditty-news-ticker
541
  msgid "Custom CSS will be added to the head of each page that includes a Ditty News Ticker."
542
+ msgstr "Custom CSS will be added to the head of each page that includes a Ditty News Ticker."
543
 
544
  #: includes/settings.php:58
545
  #: includes/settings.php:95
546
  #@ ditty-news-ticker
547
  msgid "&nbsp;"
548
+ msgstr "&nbsp;"
549
 
550
  #: includes/settings.php:130
551
  #@ ditty-news-ticker
552
  msgid "Ditty News Ticker Settings"
553
+ msgstr "Ditty News Ticker Settings"
554
 
555
  #: includes/settings.php:144
556
  #@ ditty-news-ticker
557
  msgid "General"
558
+ msgstr "General"
559
 
560
  #: includes/settings.php:145
561
  #@ ditty-news-ticker
562
  msgid "Extension Licenses"
563
+ msgstr "Extension Licenses"
564
 
565
  #: includes/settings.php:178
566
  #@ ditty-news-ticker
567
  msgid "Add global settings to your news tickers."
568
+ msgstr "Add global settings to your news tickers."
569
 
570
  #: includes/settings.php:179
571
  #@ ditty-news-ticker
572
  msgid "Use the Custom CSS textarea to set global or individual styles to each of your tickers."
573
+ msgstr "Use the Custom CSS textarea to set global or individual styles to each of your tickers."
574
 
575
  #: includes/settings.php:188
576
  #@ ditty-news-ticker
577
  msgid "Add the licenses for each of your extensions."
578
+ msgstr "Add the licenses for each of your extensions."
579
 
580
  #: includes/taxonomies.php:21
581
  #: includes/taxonomies.php:31
582
  #@ ditty-news-ticker
583
  msgid "Categories"
584
+ msgstr "Categories"
585
 
586
  #: includes/taxonomies.php:22
587
  #@ ditty-news-ticker
588
  msgid "Category"
589
+ msgstr "Category"
590
 
591
  #: includes/taxonomies.php:23
592
  #@ ditty-news-ticker
593
  msgid "Search Categories"
594
+ msgstr "Search Categories"
595
 
596
  #: includes/taxonomies.php:24
597
  #@ ditty-news-ticker
598
  msgid "All Categories"
599
+ msgstr "All Categories"
600
 
601
  #: includes/taxonomies.php:25
602
  #@ ditty-news-ticker
603
  msgid "Parent"
604
+ msgstr "Parent"
605
 
606
  #: includes/taxonomies.php:26
607
  #@ ditty-news-ticker
608
  msgid "Parent:"
609
+ msgstr "Parent:"
610
 
611
  #: includes/taxonomies.php:27
612
  #@ ditty-news-ticker
613
  msgid "Edit Category"
614
+ msgstr "Edit Category"
615
 
616
  #: includes/taxonomies.php:28
617
  #@ ditty-news-ticker
618
  msgid "Update Category"
619
+ msgstr "Update Category"
620
 
621
  #: includes/taxonomies.php:29
622
  #@ ditty-news-ticker
623
  msgid "Add New Category"
624
+ msgstr "Add New Category"
625
 
626
  #: includes/taxonomies.php:30
627
  #@ ditty-news-ticker
628
  msgid "New Category"
629
+ msgstr "New Category"
630
 
631
  #: includes/widget.php:42
632
  #@ ditty-news-ticker
633
  msgid "Displays a Ditty News Ticker."
634
+ msgstr "Displays a Ditty News Ticker."
635
 
636
+ #: includes/widget.php:137
637
  #@ ditty-news-ticker
638
  msgid "Title:"
639
+ msgstr "Title:"
640
 
641
+ #: includes/widget.php:143
642
  #@ ditty-news-ticker
643
  msgid "Select a Ticker:"
644
+ msgstr "Select a Ticker:"
645
 
646
+ #: includes/widget.php:161
647
  #@ ditty-news-ticker
648
  msgid "Display Ticker Title?"
649
+ msgstr "Display Ticker Title?"
650
+
651
+ #: includes/help.php:112
652
+ #@ ditty-news-ticker
653
+ msgid "View DNT extensions"
654
+ msgstr "View DNT extensions"
655
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_i
4
  Tags: ticker, news, news ticker, rotator, data rotator, lists, data
5
  Requires at least: 3.2
6
  Tested up to: 3.5.1
7
- Stable tag: 1.0.4
8
  License: GPL2
9
 
10
  Ditty News Ticker is a multi-functional data display plugin.
@@ -52,6 +52,13 @@ Each individual Ticker post has multiple settings to customize.
52
 
53
  == Changelog ==
54
 
 
 
 
 
 
 
 
55
  = 1.0.4 =
56
  * Added 'languages' folder for localization.
57
  * Added an 'in_widget' attribute to tickers displayed in widgets.
@@ -74,6 +81,9 @@ Each individual Ticker post has multiple settings to customize.
74
 
75
  == Upgrade Notice ==
76
 
 
 
 
77
  = 1.0.4 =
78
  Added 'languages' folder for localization. Added an 'in_widget' attribute to tickers displayed in widgets. Updated 'sort' metaboxer code.
79
 
4
  Tags: ticker, news, news ticker, rotator, data rotator, lists, data
5
  Requires at least: 3.2
6
  Tested up to: 3.5.1
7
+ Stable tag: /trunk/
8
  License: GPL2
9
 
10
  Ditty News Ticker is a multi-functional data display plugin.
52
 
53
  == Changelog ==
54
 
55
+ = 1.0.5 =
56
+ * Updated metaboxer scripts.
57
+ * Updated direct function output.
58
+ * Updated ticker types link.
59
+ * Fixed rotator numbers padding.
60
+ * Fixed limited number of DNT in widget drop down issue.
61
+
62
  = 1.0.4 =
63
  * Added 'languages' folder for localization.
64
  * Added an 'in_widget' attribute to tickers displayed in widgets.
81
 
82
  == Upgrade Notice ==
83
 
84
+ = 1.0.5 =
85
+ Updated metaboxer scripts. Updated direct function output. Updated ticker types link. Fixed rotator numbers padding. Fixed limited number of DNT in widget drop down issue.
86
+
87
  = 1.0.4 =
88
  Added 'languages' folder for localization. Added an 'in_widget' attribute to tickers displayed in widgets. Updated 'sort' metaboxer code.
89