0

I need a Greasemonkey script to customize one of my frequently visited site. How can I make sure my script will excute first, modify the html, end sucessfully, only then allow any inline script runs?

EDIT: I've splitted my original question into 2. one goes here: Find all elements have any attribute other than some specified attributes (solved)

my real goal with the page is targeting some special elements (which I got from my other question) but an inline script will change some elements's attributes, or even remove those elements. If that script CAN'T be blocked, what should I do?

Community
  • 1
  • 1
Erik
  • 103
  • 1
  • 9
  • This can be done, but it has a high PITA-to-usefulness ratio. What is your ***real*** goal with the page? – Brock Adams Jan 09 '13 at 00:45
  • @Brock Adams I've just updated my question. Please have a look. – Erik Jan 09 '13 at 05:07
  • 1
    Still not quite what we need to work with, see [here](http://stackoverflow.com/questions/how-to-ask), and [here](http://meta.stackexchange.com/q/156810/148310). Might work up an answer for the general case later, if I feel frisky. Meanwhile look at [this answer](http://stackoverflow.com/a/10468821/331508). – Brock Adams Jan 09 '13 at 05:24
  • Your link is really helpful and exactly what I want. Sorry, I should have searched more thoroughly. (In fact, I got some similar advices, about @run-at document-start, but couldn't come up to something on my own). About my other question, yes, I did follow through it, I checked the appropriate answer, then... unchecked it (then checked again..), just need more time to consider the answers. anyway, thanks a lot! – Erik Jan 09 '13 at 10:45
  • possible duplicate of [Stop execution of Javascript function (client side) or tweak it](http://stackoverflow.com/questions/3972038/stop-execution-of-javascript-function-client-side-or-tweak-it) – Brock Adams Jan 09 '13 at 11:07
  • Sounds like you found what you need. If so, you should flag to close this question as a duplicate of that one. (You won't lose your score, it just helps prevent spamming the same info while possibly aiding the next guy's search.) – Brock Adams Jan 09 '13 at 11:09

0 Answers0