Osclass Support Forums - Rackons.in

Osclass Plugin Support => Market Price with Discount => Topic started by: Demyka on February 26, 2019, 12:23:46 AM

Title: Home page discount display
Post by: Demyka on February 26, 2019, 12:23:46 AM
Hello,

Please, how can I make the discount display in last listings of home page. It is displayed only in item page.

My theme is Bitfinder

Best regards
Title: Re: Home page discount display
Post by: Administrator on February 26, 2019, 12:24:45 AM
Hello ,

Please mention your theme and website name here, then we will check for that.
Title: Re: Home page discount display
Post by: Administrator on February 26, 2019, 12:28:30 AM
Hello ,

Please mention your theme and website name here, then we will check for that.

and you put below code on loop-single.php or loop-single-premium.php :
Code: [Select]
<?php if(function_exists('osc_mrp_number')){ osc_mrp_number();} ?>
Title: Re: Home page discount display
Post by: Demyka on February 26, 2019, 03:52:15 AM
Theme: Bitfinder

Unfortunately, there are no loop-single.php or loop-single-premium.php files in this theme.
Title: Re: Home page discount display
Post by: Administrator on February 26, 2019, 03:54:09 AM
Please PM your Cpanel login details then we will check files and try to show on home page for Bitfinder theme.
Title: Re: Home page discount display
Post by: Administrator on February 26, 2019, 05:26:35 AM
https://ouadakar.net/ please check your website home page.

please check screenshot : https://prnt.sc/mq9vcd (https://prnt.sc/mq9vcd)
Title: Re: Home page discount display
Post by: Administrator on February 26, 2019, 05:48:40 AM
ok, please mark your question as solve.
Title: Re: Home page discount display
Post by: Tango on November 30, 2021, 11:45:46 AM
Hello,

I'm having the same issue.
I've tried everything and still the function doesn't appear on the homepage, it works only for the item page.

My loop-single.php code is:
Code: [Select]
<?php if (osc_price_enabled_at_items() && osc_item_price() != "") : ?>
    <div class="overlay overlay-top overlay-left-0 overlay-price">
        <span class="bg-dark text-inverse p-sm d-b font-secondary loop-item-price">
            <?php echo osc_format_price(osc_item_price()); ?>
        </span>
        <?php if(function_exists('osc_mrp_number')) { osc_mrp_number(); } ?>
    </div>
<?php endif; ?>

I guess the issue is that the function doesn't fetch the item id on the homepage, that's why it probably returns empty.

Can you please guide me on how to fix it (testing on localhost)?
Thanks!