This script allows you to display and copy the URLs of videos that are playing on webpages. Here's how you can use this code:
-
Install a UserScript Manager: To use this user script, you need a UserScript manager extension installed in your browser. Popular options include Tampermonkey (for Chrome) and Greasemonkey (for Firefox). Install one of these extensions based on the browser you're using.
-
Create a New UserScript: Open your UserScript manager extension and create a new UserScript.
-
Copy and Paste the Code: Copy the code and paste it into the UserScript editor. . https://github.com/Rainman69/video-link-grabber/blob/main/video%20url.js
-
Save and Enable the UserScript: Save the UserScript, and the UserScript manager will enable it automatically.
-
Play Videos on Webpages: Visit any webpage that contains video elements (e.g., HTML5
<video>
elements). -
Display Video URLs: While playing a video, click anywhere on the webpage. A container will appear at the top left corner of the page, displaying the URLs of the videos currently playing. If no video URLs are found, it will show a message indicating that no video URLs were found.
-
Copy Video URL: To copy a video URL, click on the displayed URL. The URL will be copied to your clipboard.
-
Confirmation Message: After copying a URL, a confirmation message will briefly appear, indicating that the URL has been copied. The message will disappear after a few seconds, and the display will update with the video URLs again.
-
Automatic Updates: The display will automatically update whenever the video elements on the page change, ensuring that you always have the latest video URLs.
-
Uninstall or Disable the UserScript: If you no longer want to use the video URL display feature, you can disable or uninstall the UserScript through your UserScript manager extension.
That's it!