I have this code to fetch user ads
The first problem is that member ads are fetched on the same page as the item
The original is that the user's advertisements are fetched without the advertisement in the element
It means new advertisements from the member other than the advertisement on the item's page
If we change this
findByUserID(osc_item_user_id(), 1, 6);
findByUserID(osc_item_user_id(), 0, 6);
All ads will be fetched from the member with the same ad on the item's page
But what I want is to show ads other than the one on the item's page
second command
If a member has only one ad, this should disappear
<div class="products-from"><a href="<?php echo osc_user_public_profile_url( osc_item_user_id() ); ?>" ><?php printf(__('Products ', 'Them')); ?><?php echo osc_item_contact_name(); ?></a></div>
But it is still visible without ads
<?php
if (osc_item_user_id() != '') {
$aItems = Item::newInstance()->findByUserID(osc_item_user_id(), 1, 6);
View::newInstance()->_exportVariableToView('items', $aItems);
?>
<div class="box user-products">
<div class="products-from"><a href="<?php echo osc_user_public_profile_url( osc_item_user_id() ); ?>" ><?php printf(__('Products ', 'Them')); ?><?php echo osc_item_contact_name(); ?></a></div>
<?php
while (osc_has_items()) {
if (osc_count_item_resources()) {
osc_get_item_resources();
?>