Vimeo: show the video ID
Displays the numeric ID of the current video in a small pinned badge in the corner of the screen.
Code to copy
// Show the numeric Vimeo video ID in a small fixed badge
function showId() {
const m = location.pathname.match(/\/(\d{6,})/);
let badge = document.getElementById('jz-vmo-id');
if (!m) { if (badge) badge.remove(); return; }
if (!badge) {
badge = document.createElement('div');
badge.id = 'jz-vmo-id';
badge.style.cssText = 'position:fixed;bottom:8px;left:8px;z-index:99999;background:#000;color:#0ff;font:12px monospace;padding:3px 7px;border-radius:4px;';
document.body.appendChild(badge);
}
badge.textContent = 'video id: ' + m[1];
}
showId();
const obs = new MutationObserver(showId);
obs.observe(document.documentElement, { childList: true, subtree: true });
How to use this example
- Copy the code with the button above.
- Install JustZix (2 minutes) and open the extension on the target page.
- Add a new rule matching that page.
- Paste the code into the rule's JavaScript panel and save — it runs on every page visit.
Rate this example
No ratings yet — be the first.