changing date to unix seconds