Quantcast
Channel: jQuery Library for SharePoint Web Services
Viewing all articles
Browse latest Browse all 6517

New Post: Need Help Using UpdateListItems

$
0
0
This is a good method. I'm a bit weary of creating an array to simply prepend a "0" to the number though. Here's what I have used a bunch:
        isoDate = function( d ) {
            //defaults to new date
            d = d || new Date();

            function pad( n ) {
                return n < 10 ? '0' + n : n;
            }

            return d.getUTCFullYear() + '-' +
                pad( d.getUTCMonth() +1 ) + '-' +
                pad( d.getUTCDate() ) + 'T' +
                pad( d.getUTCHours() ) + ':' +
                pad( d.getUTCMinutes() )+ ':' +
                pad( d.getUTCSeconds() )+ 'Z';
        },
Cheers,
Matthew

Viewing all articles
Browse latest Browse all 6517

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>