Advertisement
Guest User

TheWheatisHeat96 title lister v1.1

a guest
May 26th, 2023
12
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
JavaScript 0.49 KB | Source Code | 0 0
  1. var titles="";
  2. a_tags=document.getElementsByTagName("a");
  3. for (var count=46; count < a_tags.length; count++) {
  4. var current_title=a_tags[count].getAttribute("title");
  5. if(current_title!=null) /* filter invalid data */ {
  6.     var video_id=a_tags[count].getAttribute("href").replace(/.*watch\?v=/,""); /* extract IDs */
  7.     if (video_id.length == 11) /* filter invalid data */ {
  8.         titles+="\n"+video_id+"\x09"+current_title; /* add to title */
  9.         }
  10.     };
  11. }
  12. document.body.innerHTML+="<pre>"+titles+"</pre>";
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement