EmsAutoFill

中華郵政EMS進度查詢自動從網址帶入單號

  1. // ==UserScript==
  2. // @name EmsAutoFill
  3. // @namespace http://tampermonkey.net/
  4. // @version 0.0.1
  5. // @description 中華郵政EMS進度查詢自動從網址帶入單號
  6. // @author AndrewWang
  7. // @include https://postserv.post.gov.tw/pstmail/main_mail.html*
  8. // @license MIT
  9. // ==/UserScript==
  10.  
  11. (function() {
  12. 'use strict';
  13.  
  14. setTimeout(() => {
  15. const input = document.getElementById('MAILNO');
  16. if (input) {
  17. const params = new URLSearchParams(window.location.search);
  18. let targetTxn = params.get('targetTxn');
  19. let sn = params.get('sn');
  20.  
  21. if (targetTxn == 'EB500200' && sn != undefined) {
  22. input.focus();
  23. input.value = sn;
  24. input.dispatchEvent(new Event('input', { bubbles: true }));
  25.  
  26. document.getElementById('captcha').focus();
  27. }
  28. }
  29. }, 700);
  30. })();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址