nick_sh Posted July 16, 2022 Share Posted July 16, 2022 I'm trying to make some customizations to the events page, but the timestamps Squarespace provides are somehow strange: so e.g. this is startDate: 1657643425538 If I do var date1 = new Date(1657643425538).toString() startDate.toString(date1) // Tue Jul 12 2022 19:30:25 But the correct date set for the event is Friday 23, 2002, 9 AM. So what am I doing wrong? or what would be the best way to transform timestamp into correct date / time? Beyondspace 1 Link to comment
paul2009 Posted July 16, 2022 Share Posted July 16, 2022 Can you provide a few details about your ultimate goal? What are you trying to change about the Events page? Also, it is always helpful if you can provide a public link to the page you are working on so that we can see what you're seeing. About: SQSP User for 17 yrs. Circle Leader since 2017. I value honesty, transparency, diversity and good design ♥. Work: Founder of SF Digital, building Squarespace Extensions to supercharge your commerce website. Content: Links in my posts may refer to SF Digital products or may be affiliate links. If my advice helped, you can thank me by clicking one of the feedback emojis below. I love coffee too. Link to comment
Beyondspace Posted May 17 Share Posted May 17 I think timezone has been taken into account, so you have to assign correct timezone to the date value BeyondSpace - Squarespace Website Developer 🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox) 🗓️ Delivery Date Picker (Squarespace Date format) 💫 Animated Buttons (Referral URL) 🥳 Sparkplugin Customisations Browsers (Browse +100 Spark plugin customisations) 🥳 Elfsight Template Browsers (Browse +1000 Elfsight widget Templates) If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you! Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment