In order to make the module show more than 2 digits of days, you have to do the following changes:
1) Go to the (jquery.countdown.js) file, which can be found in the (js) folder inside our module files.
2) In around line (60), simply, change the (-2) for the days slice to be (-3 or -4 or -5) as per your digits needs (only change it for days), and according to this number, add zeros (0) to match the case when the countdown have less days. The result will be something like that: (("000" + days).slice(-4)). In this example, we increased it to show 4 digits, that's why we have three zeros to show even if we have 1 day remaining.
3) Update lines 15 and 16 in the same file (jquery.countdown.js), the format and the startTime must have the same format. in our previous example of 4 digits of days, the results will be something like this:
format: "dddd:hh:mm:ss",
startTime: "0001:12:32:55",
Save the file and close it.
4) This change will require you to update the description below the digits (Days, Hours, ...etc) so it will show under that numbers. For this, you have to go to the (helper.php) file which can be found directly inside our module folder, and go to around line (98) and override the Div style for the Days only, and add special new width to match your needs, so it will appear something like:
'.$oCDdaysL.'
.
That's it, you will have 4 digits of days, and everything shall work fine.
The result will be something like this:
https://o-sense.com/joomla/ocountdown.html
Feel free to contact us for any further assistance.
Regards.
Vielleicht kanns ja jemand gebrauchen! Eingestellt hab ichs, also funktionieren tuts!
Keine Kommentare:
Kommentar veröffentlichen