Search in support tickets

#223 – Choosing duration of ads - display duration name

Posted in ‘Support’
This is a public ticket. Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.
Thursday, 25 January 2018 15:19 CET
hvtechnology
Hello,

I need to show on duration select, the name of duration option not the duration length and price. Before it displays the name but now it doesn't. Maybe it is on configuration but I am not seeing it!

I need your help.

Thank you!
Custom Fields
Joomla Version
3.8.3
PHP Version
5.6
Product
AdsManager
Product Version
3.1.11
Attachment
Thursday, 25 January 2018 17:26 CET
loic
Hello,

In components/com_paidsystem/api.paidsystem.php, replace the var $duration->duration by $duration->title

if ($duration->duration == 0) {
                        if ($duration->credits > 0)
                            echo "<option $selected value='$duration->id'>".sprintf(JText::_('PAIDSYSTEM_NO_EXPIRATION_WITH_PRICE'), getPrice($duration->credits))."</option>";
                        else
                            echo "<option $selected value='$duration->id'>".JText::_('PAIDSYSTEM_NO_EXPIRATION')."</option>";
                    } else {
                        if ($duration->credits > 0)
                            echo "<option $selected value='$duration->id'>".sprintf(JText::_('PAIDSYSTEM_DURATION_DISPLAY'),$duration->duration, getPrice($duration->credits))."</option>";
                        else
                            echo "<option $selected value='$duration->id'>".sprintf(JText::_('PAIDSYSTEM_DURATION_SHORT_DISPLAY'),$duration->duration)."</option>";
                    }


Best regards.
 
Tuesday, 30 January 2018 10:10 CET
hvtechnology
I found this code in
components/com_paidsystem/views/edit/tmpl/default.php
OR
templates/TAMPLATE_NAME/html/com_paidsystem/edit/default.php

Thank you!
This ticket is closed, therefore read-only. You can no longer reply to it. If you need to provide more information, please open a new ticket and mention this ticket's number.