get current time?



  • How to get the current time with format:keyid=2020213155734
    html sources like this:

    "
    function getTimeStamp() {
    time_object = new Date();
    time = ""+time_object.getFullYear()+time_object.getMonth()+
    time_object.getDate()+time_object.getHours()+time_object.getMinutes()+
    time_object.getSeconds();
    document.form.keyid.value=time;
    }

    output likes this
    keyid=2020213155734

    any suggestions?
    thanks


  • Donator

    copy paste this in your config and use <keyid> to get the time

    BEGIN SCRIPT JAVASCRIPT
    time_object = new Date();
    time = ""+time_object.getFullYear()+time_object.getMonth()+
    time_object.getDate()+time_object.getHours()+time_object.getMinutes()+
    time_object.getSeconds();
    var keyid=time;
    END SCRIPT -> VARS "keyid"
    

    you could also do it with function & parse blocks but it would take like 12 blocks or something 🙂



  • @Itamai you are so nice thanks much


Log in to reply