OS Property support center

Show adress

  • DThx
  • Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
10 years 6 months ago #52070 by DThx
Show adress was created by DThx
Hi dam,

In manage properties > if show adress is "NO" ,
adress doesn' t display in front-end details layout, but price and M² supersede it?
how to avoid it ?
Thank
Regards
Didier

Please Log in or Create an account to join the conversation.

More
10 years 6 months ago #52095 by Mr. Dam
Replied by Mr. Dam on topic Show adress
Hi Didier,
Can you please let me know the screenshot for more details?
Thanks
Dam

Please Log in or Create an account to join the conversation.

  • DThx
  • Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
10 years 6 months ago #52117 by DThx
Replied by DThx on topic Show adress
Hi Dam,

You can see what i mean attached

we don't wish adress, either price and m²
regards
Didier
Attachments:

Please Log in or Create an account to join the conversation.

More
10 years 6 months ago #52123 by Mr. Dam
Replied by Mr. Dam on topic Show adress
Hi,
Please open file:
components > com_osproperty > classes > listing.html.php
find
if($row->show_address == 1){
$row->subtitle = OSPHelper::generateAddress($row);
}else{
$addInfo = array();
$addInfo1 = array();
if($row->price > 0){
$addInfo1[] = OSPHelper::generatePrice($row->curr,$row->price);
}
if(($row->bed_room > 0) and ($configClass == 1)){
$addInfo[] = $row->bed_room." ".JText::_('OS_BEDROOMS');
}
if(($row->bath_room > 0) and ($configClass == 1)){
$addInfo[] = OSPHelper::showBath($row->bath_room)." ".JText::_('OS_BATHROOMS');
}
if(($row->rooms > 0) and ($configClass == 1)){
$addInfo[] = $row->rooms." ".JText::_('OS_ROOMS');
}
if(($row->square_feet > 0) and ($configClass == 1)){
$addInfo[] = $row->square_feet." ".OSPHelper::showSquareSymbol();
}
$addInfo1[] = implode(", ",$addInfo);
$row->subtitle = implode(" | ",$addInfo1);
}

And change to

if($row->show_address == 1){
$row->subtitle = OSPHelper::generateAddress($row);
}


Good luck
Dam

Please Log in or Create an account to join the conversation.

  • DThx
  • Topic Author
  • Offline
  • Senior Member
  • Senior Member
More
10 years 6 months ago #52125 by DThx
Replied by DThx on topic Show adress
HI dam,
Done, it's ok.
Thank
Didier

Please Log in or Create an account to join the conversation.

Moderators: Mr. DamNguyen Phu Quan