| 1 |
<?php |
| 2 |
/** |
| 3 |
* |
| 4 |
*/ |
| 5 |
|
| 6 |
// No direct access allowed. |
| 7 |
defined('ABSPATH') or die("Access denied"); |
| 8 |
?> |
| 9 |
<html xmlns="http://www.w3.org/1999/xhtml"> |
| 10 |
<head> |
| 11 |
<title></title> |
| 12 |
<link rel="stylesheet" type="text/css" href="<?php echo CJTOOLBOX_HTML_CONPONENTS_URL ?>/checkbox-list/public/css/checkbox-list.css" /> |
| 13 |
<?php wp_print_head_scripts() ?> |
| 14 |
<?php wp_print_styles() ?> |
| 15 |
</head> |
| 16 |
<body> |
| 17 |
<div id="cjtoolbox_popup"> |
| 18 |
<form id="settings-page"> |
| 19 |
<div id="settings-tabs"> |
| 20 |
<ul class="navigator"> |
| 21 |
<?php |
| 22 |
foreach ($this->pages as $page) : |
| 23 |
// Tab for each page! |
| 24 |
// Hidden field to always have somthing submitted in the server side, |
| 25 |
// if nothing submitted not save loop will processed, and therefor |
| 26 |
// cannot save empty list of checkboxes as in the case wityh metabox! |
| 27 |
?> |
| 28 |
<li> |
| 29 |
<a href="#<?php echo $page['name'] ?>"><?php echo cssJSToolbox::getText($page['displayName']) ?></a> |
| 30 |
<input type="hidden" name="settings[<?php echo $page['name'] ?>][page_info][name]" value="<?php echo $page['name'] ?>" /> |
| 31 |
</li> |
| 32 |
<?php |
| 33 |
endforeach; |
| 34 |
?> |
| 35 |
</ul> |
| 36 |
<div class="tabs"> |
| 37 |
<?php |
| 38 |
foreach ($this->pages as $page) : |
| 39 |
$pageTemplateParams = array( |
| 40 |
'settings' => $this->settings->loadPage($page['name']), |
| 41 |
'page' => $page, |
| 42 |
); |
| 43 |
?> |
| 44 |
<div id="<?php echo $page['name'] ?>"> |
| 45 |
<h3><?php echo $page['displayName'] ?></h3> |
| 46 |
<div class="settings-page-content"> |
| 47 |
<?php echo $this->getPage($page['name'], $pageTemplateParams) ?> |
| 48 |
</div> |
| 49 |
</div> |
| 50 |
<?php |
| 51 |
endforeach; |
| 52 |
?> |
| 53 |
</div> |
| 54 |
</div> |
| 55 |
<input type="submit" name="" value="Submit" class="cjt-submit" /> |
| 56 |
</form> |
| 57 |
</div> |
| 58 |
<?php wp_print_footer_scripts() ?> |
| 59 |
</body> |
| 60 |
</html> |