Greasy Fork is available in English.

pixiv ID

show pixiv ID in pixiv. pixiv にてユーザー ID を表示する

Du musst eine Erweiterung wie Tampermonkey, Greasemonkey oder Violentmonkey installieren, um dieses Skript zu installieren.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

Sie müssten eine Skript Manager Erweiterung installieren damit sie dieses Skript installieren können

(Ich habe schon ein Skript Manager, Lass mich es installieren!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name pixiv ID
// @description show pixiv ID in pixiv. pixiv にてユーザー ID を表示する
// @version 1.0
// @include http://www.pixiv.net/*
// @namespace https://greasyfork.org/users/8032
// ==/UserScript==

;(function() {
  "use strict";
  var addUIDNode = function() {
    var KEY_URL = "http://www.pixiv.net/stacc/";
    var NODE_ID = "userjs-user-id-item";
    var src = document.querySelector("a.tab-feed");
    var dst = document.querySelector(".user-relation");
    var uidnode = document.querySelector("#" + NODE_ID);
    if (!uidnode && src && dst) {
      var userID = src.href.slice(KEY_URL.length).match(/[-\w]*/)[0];
      var li = document.createElement("li");
      var a = document.createElement("a");
      li.id = NODE_ID;
      a.textContent = userID;
      a.href = "http://drawr.net/" + userID;
      a.style.display = "inline-block";
      a.style.paddingLeft = "24px";
      a.style.backgroundImage = "url(http://drawr.net/images/icon_top.gif)";
      a.style.backgroundRepeat = "no-repeat";
      li.appendChild(a);
      dst.appendChild(li);
    }
  };
  if (document.readyState === "complete") addUIDNode();
  else addEventListener("DOMContentLoaded", addUIDNode);
  addEventListener("popstate", addUIDNode);
})();