PluginProbe
Social Share Buttons / 1.16
Social Share Buttons v1.16
trunk 0.9 1.0 1.1 1.1.1 1.1.2 1.10 1.11 1.12 1.15 1.16 1.17 1.18 1.19 1.2 1.20 1.3 1.30 1.4 1.5 1.6 1.7 1.8 1.9
share-button / classes / blocks / admin_block.php

admin_block.php in Social Share Buttons 1.16, at classes/blocks/admin_block.php

67 lines 1.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 namespace MBSocial;
3 defined('ABSPATH') or die('No direct access permitted');
4
5 use \MaxButtons\maxField as maxField;
6 use \MaxButtons\maxBlocks as maxBlocks;
7 use \MaxButtons\maxButton as maxButton;
8 use \MaxButtons\maxUtils as maxUtils;
9
10
11
12 $collectionBlock["admin"] = array('class' => "adminBlock",
13 'order' => 999);
14
15 class adminBlock extends block
16 {
17
18 public function admin()
19 {
20
21 return;
22
23 $data = $this->data;
24 $preset['style'] = $data['style'];
25 $preset['layout'] = $data['layout'];
26 $preset['effect'] = $data['effect'];
27 $preset['count']= array('font_count_size' => $data['count']['font_count_size']);
28 ?>
29 <div class='current'>
30 <p>Current Preset: </p>
31
32 <p><?php echo json_encode($preset); ?></p>
33 </div>
34 <?php
35
36 $presets = new presets();
37 $sets = $presets->get();
38
39 $set = json_decode($sets['round'], ARRAY_A);
40
41 echo "<PRE>"; print_R($set); echo "</pre>";
42
43 $args = array('preview' => true,
44 'load_type' => 'inline',
45 'echo' => false,
46 'compile' => true,
47 );
48
49 $stylename = $set['style']['mbs-style'];
50 $style = styles::getStyle($stylename);
51
52 $collection = new collection(0 );
53 $collection->setStyle($style);
54
55 foreach($set as $blockname => $blockdata)
56 {
57 $collection->setData($blockname, $blockdata);
58 }
59
60 echo $collection->display($args);
61
62
63 }
64
65 }
66 ?>
67