Results 1 to 11 of 11
  1. #1
    Ameer's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Location
    MPGH
    Posts
    14,670
    Reputation
    2353
    Thanks
    6,358

    Tampermonkey / Grease monkey

    I know this should be in the programming section "Java scripting" I guess , but i need some quick info.
    I need some quick help on this , i have no background in JS.
    Code:
    document.body.innerHTML= document.body.innerHTML.replace(/<td align="center" valign="middle" title="230">230</td>/g,"<td align="center" valign="middle" title="333">333</td>");
    Why ^ this doesn't work for example ?
    Code:
    <td align="center" valign="middle" title="230">230</td>
    is the part in the website that I want to edit the number in it to be 333 or any other number ?

  2. #2
    Acid's Avatar
    Join Date
    Oct 2013
    Gender
    male
    Location
    South of Heaven
    Posts
    1,559
    Reputation
    82
    Thanks
    174
    I'm a big greasemoney fan, Reek's anti ad-block killer is the bomb
    Give me bitcoin, I guess.. 1aoAPueWDGiTybBR82hLVaFc7y9oyTjgz




  3. #3
    Ameer's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Location
    MPGH
    Posts
    14,670
    Reputation
    2353
    Thanks
    6,358
    Quote Originally Posted by Acid View Post
    I'm a big greasemoney fan, Reek's anti ad-block killer is the bomb
    You're not helping tho

  4. #4
    Entity's Avatar
    Join Date
    Jan 2015
    Gender
    male
    Posts
    898
    Reputation
    67
    Thanks
    208
    My Mood
    Relaxed
    I don't know what you're trying to do, document.body.innerHTML replaces everything inside the body tag.

    Only error I can see is that the argument of document.body.innerHTML.replace aren't inside a ' ' - other than that, I don't see anything wrong -.
    Quote Originally Posted by Endl3ss View Post
    welcome back Graphicx GOD

  5. #5
    Ameer's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Location
    MPGH
    Posts
    14,670
    Reputation
    2353
    Thanks
    6,358
    Quote Originally Posted by Capi View Post
    I don't know what you're trying to do, document.body.innerHTML replaces everything inside the body tag.

    Only error I can see is that the argument of document.body.innerHTML.replace aren't inside a ' ' - other than that, I don't see anything wrong -.
    Let's say I want the script to change your Posts count "666" to "999". ?

  6. #6
    Entity's Avatar
    Join Date
    Jan 2015
    Gender
    male
    Posts
    898
    Reputation
    67
    Thanks
    208
    My Mood
    Relaxed
    Quote Originally Posted by Ameer View Post

    Let's say I want the script to change your Posts count "666" to "999". ?
    document.body.innerHTML= document.body.innerHTML.replace('666', '999');
    Quote Originally Posted by Endl3ss View Post
    welcome back Graphicx GOD

  7. #7
    Ameer's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Location
    MPGH
    Posts
    14,670
    Reputation
    2353
    Thanks
    6,358
    Quote Originally Posted by Capi View Post
    document.body.innerHTML= document.body.innerHTML.replace('666', '999');
    Banned you. because it didn't work.

  8. The Following User Says Thank You to Ameer For This Useful Post:

    john8734 (06-20-2016)

  9. #8
    FlexGod's Avatar
    Join Date
    Sep 2010
    Gender
    male
    Location
    SouthSide
    Posts
    1,440
    Reputation
    80
    Thanks
    526
    My Mood
    Aggressive
    Quote Originally Posted by Ameer View Post

    Banned you. because it didn't work.
    Damn is it that serious
    NightOwl


  10. #9
    Ameer's Avatar
    Join Date
    Aug 2011
    Gender
    male
    Location
    MPGH
    Posts
    14,670
    Reputation
    2353
    Thanks
    6,358
    Quote Originally Posted by flex1178 View Post
    Damn is it that serious
    No, it was just a coincidence.
    I'm no staff..

    /bump

  11. #10
    Entity's Avatar
    Join Date
    Jan 2015
    Gender
    male
    Posts
    898
    Reputation
    67
    Thanks
    208
    My Mood
    Relaxed
    Quote Originally Posted by Ameer View Post

    No, it was just a coincidence.
    I'm no staff..

    /bump
    https://www.w3schools.com/jsref/prop_doc_body.asp
    https://developer.mozilla.org/en-US/...ment/innerHTML
    Quote Originally Posted by Endl3ss View Post
    welcome back Graphicx GOD

  12. #11

Similar Threads

  1. HELP me my monkey hits me
    By llvengancell in forum WarRock - International Hacks
    Replies: 9
    Last Post: 06-06-2007, 06:56 AM
  2. monkey
    By Gourav2122 in forum General
    Replies: 8
    Last Post: 03-27-2007, 11:49 PM
  3. The Monkey
    By AthlaS in forum Spammers Corner
    Replies: 13
    Last Post: 12-11-2006, 06:29 PM
  4. I Like Monkeys
    By Jackal in forum Spammers Corner
    Replies: 18
    Last Post: 12-11-2006, 05:59 PM
  5. Karate Monkey, not Bobo
    By arunforce in forum General
    Replies: 1
    Last Post: 07-19-2006, 11:40 AM