I have a text file ,want to open in python and take the date and time (in header) then change it to seconds (timestamp). but result is not the same as online websites. Code:
with open('sample for north - Kopie.txt', "r") as f:
content = f.readlines()
for x in content :
day = float (content [0][:2])
month = float (content [0][3:5])
year = float (content [0][6:10])
hour = float (content [0][10:13])
minn = float (content [0][14:16])
second = float (content [0][17:19])
time = float ((((year-1970)*31556926)+((month-1)*2629743)+((day-1)*86400)+((hour)*3600)+((minn)*60)+second))
for 13.07.2015 09:38:17 result of program is 1436911625 but result of websites are 1436780297.