| 1 |
<?php |
| 2 |
namespace MBSocial; |
| 3 |
defined('ABSPATH') or die('No direct access permitted'); |
| 4 |
|
| 5 |
// defined $post_type and $post in function |
| 6 |
use MaxButtons\maxButton as maxButton; |
| 7 |
$button = new maxButton(); // this loads the maxblocks template files |
| 8 |
|
| 9 |
$collection_ids = collections::getCollections(); |
| 10 |
|
| 11 |
if (count($collection_ids) == 0) |
| 12 |
return; // no collection no meta |
| 13 |
|
| 14 |
foreach ($collection_ids as $collection_id) |
| 15 |
{ |
| 16 |
$collection = new collection($collection_id); |
| 17 |
|
| 18 |
$collection->save_meta_boxes($post_id, $_POST); |
| 19 |
|
| 20 |
|
| 21 |
} |
| 22 |
|
| 23 |
|
| 24 |
|