Skip to content

Instantly share code, notes, and snippets.

@propertyhive
Last active July 14, 2016 16:29
Show Gist options
  • Save propertyhive/6c8abdafb75dbe4ef543370e926176e2 to your computer and use it in GitHub Desktop.
Save propertyhive/6c8abdafb75dbe4ef543370e926176e2 to your computer and use it in GitHub Desktop.
<?php
/**
* Loop Summary
*
* @author PropertyHive
* @package PropertyHive/Templates
* @version 1.0.0
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
global $property;
?>
<div class="summary">
<?php echo $property->post_excerpt; ?>
<p>
Area: <?php echo $property->location; ?>
Bedrooms: <?php echo $property->bedrooms; ?>
Property Type: <?php echo $property->property_type; ?>
</p>
<?php
$features = $property->get_features();
if ( !empty($features) )
{
?>
<div class="features">
<strong><?php _e( 'Features', 'propertyhive' ); ?></strong>
<ul>
<?php
foreach ($features as $feature)
{
?>
<li style="float:none; padding-top:0; padding-bottom:0; border:0"><?php echo $feature; ?></li>
<?php
}
?>
</ul>
</div>
<?php
}
?>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment