Support Forums - Classified Ads Script Osclass
Osclass theme support => Veronika Osclass Responsive Theme => Topic started by: terry on April 14, 2017, 10:17:00 AM
-
Hi there
How can I show certain countries in the footer location/region section instead of the current popular regions? Is there a code to do this or will I need to enter these links in manually in footer.php?
Thanks
-
You can modify it in footer.php, i do not have code
-
@terry
In footer, if you replace:
<div class="location">
<?php $regions = RegionStats::newInstance()->listRegions('%%%%', '>', 'i_num_items DESC'); ?>
<?php $i = 1; ?>
<?php foreach($regions as $r) { ?>
<?php if($i <= 12) { ?>
<span class="region-span"><a href="<?php echo osc_search_url(array('page' => 'search', 'sRegion' => $r['pk_i_id']));?>"><?php echo $r['s_name']; ?></a></span>
<?php $i++; ?>
<?php } ?>
<?php } ?>
</div>
With:
<div class="location">
<?php $countries = CountryStats::newInstance()->listCountries('%%%%', '>', 'i_num_items DESC'); ?>
<?php $i = 1; ?>
<?php foreach($countries as $r) { ?>
<?php if($i <= 12) { ?>
<span class="region-span"><a href="<?php echo osc_search_url(array('page' => 'search', 'sCountry' => $r['pk_i_id']));?>"><?php echo $r['s_name']; ?></a></span>
<?php $i++; ?>
<?php } ?>
<?php } ?>
</div>
Did not tested, but at least it is start 8)