I want to set up a voting system where, as soon as it starts, the user can see on what date the voting started. Demonstrating, voting started on 2022/10/07 at 18:40
Asked
Active
Viewed 2,193 times
1 Answers
2
You can use this library to convert timestamp to datetime https://github.com/RollaProject/solidity-datetime#timestamptodatetime
function timestampToDateTime(uint timestamp) public pure returns (uint year, uint month, uint day, uint hour, uint minute, uint second)

Stephen
- 31
- 2