您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
gamespot video Links appear in the video description next to the social buttons.
// ==UserScript== // @name gamespot expose download links // @namespace *.gamespot.* // @description gamespot video Links appear in the video description next to the social buttons. // @include *.gamespot.* // @version 1.01 // @grant none // ==/UserScript== var addLinks = function(){ var components = $('#kubrick-lead').html().split('{"f4m_stream":"')[1].split('.csmil')[0].replace(/\\/g, '').replace('/z/','/').replace('/hdv.','/video.').split(',') var base = components[0] var mediatype = components.slice(-1)[0] var toolbar = document.querySelectorAll('.news-hdr')[0]; for (var i = 1; i < components.length-1; i++) { var desiredLink = base + components[i] + mediatype; var desiredText = components[i] + " "; var link=document.createElement("a"); link.appendChild(document.createTextNode(desiredText)); link.href = desiredLink; toolbar.appendChild(link); } }; addLinks();