Important security update, please update to Osclass 3.7.4
At Osclass we have changed our Privacy Policy and Terms of Use in order to adapt them to the new General Data Protection Regulation (GDPR). We want you to know what user data we store, what we need them for, and who we share them with in each specific case. Furthermore, we are making it even easier for you to exercise your right to manage your own data.
Our goal is that you enjoy the best possible experience with our website. As the GDPR comes into force, legislation requires us that you grant us permission—both to us and our partners—to store cookies in your browser. Remember you can find more information about what we do with your data by clicking here.
I accept Osclass SL’s Terms of Use and Cookies Policy and grant them permission to manage my data.
yes, there are not all durations calculated correctly... this is why i need to work on this plugin
Quote from: Liath on September 04, 2017, 02:12:46 amyes, there are not all durations calculated correctly... this is why i need to work on this pluginSo Daniel (_Conejo) was right after all about it .....
I was right about what?
after looking at the code,the date seems to not be checked against the category limit. the select/dropdown is, but not when inserting the data, we should fix thator an user may set a non expired listing.with the liath's plugin, you need to modify your theme with each update, why not use the proper hooks to do it?
After reviewing the plugin, they found an issue that the ad duration was set to unlimited in some cases, i didnt found the error for now and didnt uploaded it again.
No need for a plugin, it's already in the core, the theme needs to include it :https://github.com/osclass/Osclass/blob/master/oc-includes/osclass/ItemActions.php#L1184andhttps://github.com/osclass/Osclass/blob/master/oc-includes/osclass/frm/Item.form.class.php#L333-L391Just add it to your theme's form from ItemForm or maybe create it manually (to add jQuery's datepicker for example). It works with datetime values (yyyy-mm-dd hh:mm:ss) or with integer (X days). It checks against the category's expiration limit too.For bender, you could add the following to item-post.phpCode: [Select] <div class="control-group"> <label class="control-label" for="description[<?php echo osc_current_user_locale(); ?>]"><?php _e('Expiration', 'bender'); ?></label> <div class="controls"> <?php ItemForm::expiration_select(); ?> </div> </div>
<div class="control-group"> <label class="control-label" for="description[<?php echo osc_current_user_locale(); ?>]"><?php _e('Expiration', 'bender'); ?></label> <div class="controls"> <?php ItemForm::expiration_select(); ?> </div> </div>
Quote from: Aficionado on January 23, 2017, 07:50:15 pmApparently the 1 day defaults to the category expiration and in my case it was 365.Found my error and fixed it. I didnt checked for right variable on new ads posts, so durations was only saved if you have edited an ad
Apparently the 1 day defaults to the category expiration and in my case it was 365.
mail is sended