Etherscan EasyRead

change timestamp on etherscan, make it easier to be analysised.

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name         Etherscan EasyRead
// @namespace    http://tampermonkey.net/
// @version      0.6
// @description  change timestamp on etherscan, make it easier to be analysised.
// @author       verazuo
// @match        https://etherscan.io/address/*
// @match        https://etherscan.io/txs?*
// @match        https://etherscan.io/txsInternal?*
// @grant        none
// ==/UserScript==

(function() {
    'use strict';
    var t;
    if (window.location.href.match("https://etherscan.io/address/")){
        t = document.getElementById("transactions");
    } else if (window.location.href.match("https://etherscan.io/txsInternal?")){
        t = document.getElementsByClassName("card-body")[0];
    } else if (window.location.href.match("https://etherscan.io/txs?")){
        t = document.getElementById("ContentPlaceHolder1_mainrow");
    }

    var trs = t.getElementsByTagName('tr');

	for (var i=1;i<trs.length;i++)
	{
		var tr = trs[i].getElementsByTagName("td");
        if(tr.length < 3){
            continue;
        }
        var span;
        if (window.location.href.match("https://etherscan.io/txsInternal?")){
			span = tr[1].getElementsByTagName("span")[0];
        } else {
        	span = tr[2].getElementsByTagName("span")[0];
        }
        if (span === undefined){
 			continue;
        }
        var date = new Date(span.title);
        var myDate = date.getFullYear() + "-" + ("0" + (date.getMonth() + 1)).slice(-2) + "-" + ("0" + date.getDate()).slice(-2) + " " + ("0" + date.getHours()).slice(-2) + ":" + ("0" + date.getMinutes()).slice(-2)+ ":" + ("0" + date.getSeconds()).slice(-2);
        span.innerHTML=myDate;
    }
})();