Пример #1
0
            case 'checkbox':
            case 'checkboxHiddenVal':
                $htmlOptions['checked'] = (bool) $opt['value'];
                break;
        }
        if (!empty($opt['params']) && is_array($opt['params'])) {
            $htmlOptions = array_merge($htmlOptions, $opt['params']);
        }
        echo htmlCsp::$htmltype('opt_values[' . $opt['code'] . ']', $htmlOptions);
    }
    ?>
			<?php 
    if ($opt['code'] == 'template') {
        ?>
				<?php 
        echo htmlCsp::inputButton(array('value' => langCsp::_('Set Template'), 'attrs' => 'class="cspGoToTemplateTabOptionButton button button-primary" code="' . $opt['code'] . '"'));
        ?>
				<?php 
        $plTemplate = $this->optModel->get('template');
        // Current plugin template
        $tplName = $plTemplate && frameCsp::_()->getModule($plTemplate) ? frameCsp::_()->getModule($plTemplate)->getLabel() : '';
        ?>
				<div class="cspAdminTemplateSelectedName"><?php 
        langCsp::_e($tplName);
        ?>
</div>
			<?php 
    }
    ?>
			</td>
		</tr>
<script type="text/javascript">
// <!--
jQuery(document).ready(function(){
	postboxes.add_postbox_toggles(pagenow);
});
// -->
</script>
<form id="cspAdminTemplateOptionsForm">
	<div>
		<?php 
echo htmlCsp::inputButton(array('value' => langCsp::_('Сhoose Preset template'), 'attrs' => 'class="cspSetTemplateOptionButton button button-primary button-large"'));
?>
		<a href="<?php 
echo uriCsp::_(array('mod' => 'coming_soon'));
?>
" target="_blank" class="cspPreviewSiteTemplateOptionButton button button-primary button-large"><?php 
langCsp::_e('Show Preview');
//echo htmlCsp::inputButton(array('value' => langCsp::_('Сhoose Preset template'), 'attrs' => 'class="cspSetTemplateOptionButton button button-primary button-large"'));
?>
</a>
	</div>
	<div class="wrap">
		<div id="dashboard-widgets" class="metabox-holder">
			<div id="postbox-container-1" class="postbox-container" style="width: auto;">
				<div id="normal-sortables" class="meta-box-sortables ui-sortable">
				<?php 
if (!empty($this->tplOptsData)) {
    ?>
					<?php 
    $i = 1;
    ?>
Пример #3
0
<script type="text/javascript">
// <!--
jQuery(document).ready(function(){
	jQuery('#toePagesRecreate').click(function(){
		jQuery(this).sendForm({
			msgElID: 'toePagesOptionsMsg',
			data: {page: 'pagesCsp', action: 'recreatePages', reqType: 'ajax'}
		});
		return false;
	});
});
// -->
</script>
<h1><?php 
langCsp::_e('Pages Options');
?>
</h1>
<table>
	<tr>
		<td><?php 
echo htmlCsp::inputButton(array('value' => langCsp::_('Recreate Pages'), 'attrs' => 'id="toePagesRecreate"'));
?>
</td>
		<td><a href="#" class="toeOptTip" tip="<?php 
langCsp::_e('If you accidently deleted one of plugin page - Login, or Checkout, or Shopping cart for example, just click on this button - and pages, that you deleted, will be created again. Do not use it without emergency.');
?>
"></a></td>
	</tr>
</table>
<div id="toePagesOptionsMsg"></div>