PluginProbe
WPPizza – A Restaurant Plugin / 3.20
WPPizza – A Restaurant Plugin v3.20
trunk 2.16.11.28 3.19 3.19.1 3.19.2 3.19.3 3.19.4 3.19.5 3.19.6 3.19.7 3.19.7.1 3.19.7.2 3.19.7.3 3.19.7.4 3.19.8 3.19.8.1 3.19.8.2 3.19.8.3 3.19.9 3.20 3.20.1
wppizza / classes / markup / options.php

options.php in WPPizza – A Restaurant Plugin 3.20, at classes/markup/options.php

72 lines 2.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * WPPIZZA_MARKUP_OPTIONS Class
4 *
5 * @package WPPIZZA
6 * @subpackage WPPizza Options
7 * @copyright Copyright (c) 2015, Oliver Bach
8 * @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
9 * @since 3.12.14
10 *
11 */
12 if ( ! defined( 'ABSPATH' ) ) exit;/*Exit if accessed directly*/
13
14 /* ================================================================================================================================= *
15 *
16 *
17 * SIMPLY OUTPUTS SOME WPPIZZA OPTIONS SET BY SHORTCODE
18 * CLASS - WPPIZZA_MARKUP_OPTIONS
19 *
20 *
21 *
22 * ================================================================================================================================= */
23
24 class WPPIZZA_MARKUP_OPTIONS{
25
26 /******************************************************************************
27 *
28 *
29 * [construct]
30 *
31 *
32 *******************************************************************************/
33 function __construct() {
34 }
35
36 /******************************************************************************
37 *
38 *
39 * [methods]
40 *
41 *
42 *******************************************************************************/
43 /***************************************
44 [apply attributes]
45 ***************************************/
46 function attributes($atts=null){
47 /**get markup**/
48 $markup = $this->get_markup($atts);
49 return $markup;
50 }
51
52 /***************************************
53 [markup]
54 ***************************************/
55 function get_markup($atts){
56 global $wppizza_options;
57
58 if(empty($atts['page']) || empty($atts['parameter'])){
59 return '';
60 }
61 //only non arrays (otherwsie simply using the global $wppizza_options would be more appropriate one would think)
62 if(!empty($wppizza_options[$atts['page']][$atts['parameter']]) && !is_array($wppizza_options[$atts['page']][$atts['parameter']])){
63 $markup = $wppizza_options[$atts['page']][$atts['parameter']];
64 return $markup;
65 }else{
66 return '';
67 }
68 return;
69 }
70
71 }
72 ?>