# share-button/1.2/admin/page_editor.php

Social Share Buttons, version 1.2. 57 lines.

- Page: https://pluginprobe.com/plugins/share-button/1.2/code/admin/page_editor.php
- Raw: https://pluginprobe.com/plugins/share-button/1.2/raw/admin/page_editor.php
- Modified: 2018-04-19T12:12:58+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/share-button/1.2/code/admin/page_editor.php#L10-L20`.

```php
<?php
namespace MBSocial;
defined('ABSPATH') or die('No direct access permitted');

use MaxButtons\maxButton as maxButton;

$button = new maxButton(); // this loads the maxblocks template files


$title = (Install::isPro()) ? __('Wordpress Share Buttons PRO', 'mbsocial') : __('WordPress Share Buttons','mbsocial');
$header = array(
		'title' => $title,
);

$mainclass = 'maxbuttons-social-editor';
$admin = mbSocial()->admin();
$admin->header($header);


$collection_ids = collections::getCollections();


if (count($collection_ids) == 0)
	$collection_ids = array(0);


?>

<?php foreach ($collection_ids as $collection_id): ?>

<?php if ($collection_id > 0): ?>
<div class='mb-message shortcode'>
	<?php printf(__('Shortcode for manual use: [maxsocial id="%s"]','mbsocial'), $collection_id); ?>
</div>
<?php endif; ?>

<form class='mb-ajax-form' data-action='save-share'>
	<input type='hidden' name="collection_id" value="<?php echo $collection_id ?>" />


	<div class="form-actions ">
		<button type="button" class="button-primary button-save mb-ajax-submit" data-action='save_collection'><?php _e('Save', 'maxbuttons') ?></button>
	</div>

	<?php include('share_editor.php'); ?>

	<?php //$admin->output_defined_fields(); ?>



	<div class="form-actions">
		<button type="button" class="button-primary button-save mb-ajax-submit" data-action='save_collection'><?php _e('Save', 'maxbuttons') ?></button>
	</div>
	<?php $admin->footer(); ?>
</form>
<?php endforeach; ?>

```
