PluginProbe
Property Hive / 2.2.2
Property Hive v2.2.2
2.3.1 2.3.0 2.2.6 2.2.5 2.2.4 2.2.3 2.2.2 1.4.46 1.4.47 1.4.48 1.4.49 1.4.5 1.4.50 1.4.51 1.4.52 1.4.53 1.4.54 1.4.55 1.4.56 1.4.57 1.4.58 1.4.59 1.4.6 1.4.60 1.4.61 All 261 releases
propertyhive / templates / single-property / material-information.php

material-information.php in Property Hive 2.2.2, at templates/single-property/material-information.php

55 lines 1.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Single Property Material Information
4 *
5 * @author PropertyHive
6 * @package PropertyHive/Templates
7 * @version 1.0.0
8 */
9
10 if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
11
12 global $post, $property;
13
14 $material_information = $property->get_material_information();
15
16 if ( empty($material_information) )
17 {
18 return;
19 }
20 ?>
21 <div class="property-material-information" style="min-width:400px">
22
23 <h2><?php echo esc_html( __( 'Utilities & More', 'propertyhive' ) ); ?></h2>
24
25 <?php do_action( 'propertyhive_property_material_information_start' ); ?>
26
27 <?php
28 foreach ( $material_information as $key => $value )
29 {
30 $label = $key;
31 $label = str_replace("_", " ", $label);
32 $label = ucwords($label);
33 echo '<h4>' . esc_html( __( $label, 'propertyhive' ) ) . '</h4>';
34
35 if ( is_array($value) && !empty($value) )
36 {
37 foreach ( $value as $subkey => $subvalue )
38 {
39 $label = $subkey;
40 $label = str_replace("_", " ", $label);
41 $label = ucwords($label);
42
43 echo '<strong>' . esc_html( __( $label, 'propertyhive' ) ) . ':</strong> ' . esc_html($subvalue) . '<br>';
44 }
45 }
46 else
47 {
48 echo '<strong>' . esc_html( __( $label, 'propertyhive' ) ) . ':</strong> ' . esc_html($value) . '<br>';
49 }
50 }
51 ?>
52
53 <?php do_action( 'propertyhive_property_material_information_end' ); ?>
54
55 </div>