本文整理汇总了PHP中Listing::GetFormatLandArea方法的典型用法代码示例。如果您正苦于以下问题:PHP Listing::GetFormatLandArea方法的具体用法?PHP Listing::GetFormatLandArea怎么用?PHP Listing::GetFormatLandArea使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Listing
的用法示例。
在下文中一共展示了Listing::GetFormatLandArea方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getSqft
public function getSqft()
{
// copy from listing_detail.php
if ($this->property_type_2 == 42) {
//property type land
$sqft = MyFunctionCustom::convertData($this->land_area, 'sqm');
$sqftcontent = $sqft != 0 && $sqft != '' ? "{$sqft} sqft" : '';
} else {
$sqft = $this->floor_area;
$sqm = $this->floor_area;
if ($this->floor_area_unit == Listing::FLOOR_UNIT_SQM) {
$sqft = MyFunctionCustom::convertData($this->floor_area, 'sqm');
}
if ($this->floor_area_unit == Listing::FLOOR_UNIT_SQFT) {
$sqm = MyFunctionCustom::convertData($this->floor_area, 'sqft');
}
$tmp = array();
if ($sqft != 0 && $sqft != '') {
$tmp[] = "{$sqft} sqft";
}
if ($sqm != 0 && $sqm != '') {
$tmp[] = "{$sqm} sqm (built-up)";
}
$sqftcontent = implode(' / ', $tmp);
}
$s = Listing::showSqft($sqftcontent, Listing::GetFormatLandArea($this));
$arr = explode('/', $s);
return trim(str_replace('sqft', '', $arr[0]));
}
示例2: psf
?>
<span class="type ">
<?php
echo $text_price;
?>
</span>
<?php
}
?>
</p>
<p><?php
echo "{$sqf} psf (built-up)";
?>
</p>
<p><?php
echo Listing::showSqft($sqftcontent, Listing::GetFormatLandArea($model));
?>
</p>
<?php
$addressTitle = Listing::GetAddressReal($model);
?>
<p><?php
echo $addressTitle;
?>
, Singapore <?php
echo $model->postal_code;
?>
</p>
</div>
</div>