SHARE
TWEET

Untitled

a guest Mar 29th, 2012 24 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var ii = document.getElementsByClassName('gamecode');
  2. var array = []
  3. for(i in ii) {
  4.         var text = ii[i].children[0].children[0].children[1].innerText;
  5.         var goodbadobj = ii[i].children[0].children[0].children[4] === undefined ? ii[i].children[0].children[0].children[3] : ii[i].children[0].children[0].children[4];
  6.         var good;
  7.         var bad;
  8.         var cb = undefined;
  9.         if(ii[i].children[0].children[0].children[4] !== undefined) {
  10.                          good = ii[i].children[0].children[0].children[4].children[0].children[0].children[0].children[0].children[0].children[0].value;
  11.                          
  12.                          bad = ii[i].children[0].children[0].children[4].children[0].children[0].children[0].children[0].children[1].children[0].value;
  13.                          cb = ii[i].children[0].children[0].children[4].children[0].children[0].children[0].children[0].children[0].children[2].children[0].onclick;
  14.         } else {
  15.                 good = ii[i].children[0].children[0].children[3].children[0].children[0].children[0].children[0].children[0].children[0].value;
  16.                 bad = ii[i].children[0].children[0].children[3].children[0].children[0].children[0].children[0].children[1].children[0].value;
  17.  
  18.         }
  19.        
  20.         if(parseInt(good) > parseInt(bad)) {
  21.        
  22.                 array.push({'text':text,'good':good, 'bad':bad});
  23.                 if(cb !== undefined) {
  24.                         cb();
  25.                 }
  26.         }
  27.  
  28. }
  29. //console.dir(array);
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top