GreaseMonkey Script for Instructables - Auto-All Steps - Download it Now!

I whipped this up, still needs work, but it works (sorta)...
You can download it here

Now, on the Explore pages, it will automatically take you to All Steps instead of the Intro step when you click on a link.

I'm considering this open-source, so PLEASE post modifications, again I literally spent 2 minutes on this - including debug/testing time.
I know you are saying "duh its open source, its a script! moron" But what I mean is that I am encouraging modifications.

Code below if my server is down
// ==UserScript==// @name           Instructables "All Steps" Fixer// @namespace      https://www.instructables.com/tag/type:instructable/*// @description    Automatically loads All Steps instead of the Intro only// @include        https://www.instructables.com/tag/type:instructable/*// ==/UserScript==//Made by Zachninme//Although this is open-source, always leave the above line intact. Thanks.var allLinks, thisLink;allLinks = document.evaluate(    '//a[@href]',    document,    null,    XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE,    null);for (var i = 0; i < allLinks.snapshotLength; i++) {    thisLink = allLinks.snapshotItem(i);    if (thisLink.href.match(/\?/i)) {	} else {    thisLink.href += '?ALLSTEPS';	}}

(I have zachninme.com registered, but it isn't working right... *sigh*)

sort by: active | newest | oldest
1-10 of 13Next »
n-regen8 years ago
I modified your script a bit, so it automatically adds ?ALLSTEPS to the URL of all articles (on Instructables) you open.
You can download the userscript from my website:
http://www.n-regen.bplaced.de/redir.php?file=Instructables_allsteps.user.js
ringai n-regen2 years ago

WEBSITE IS DEAD - 06 Jan 2015

n-regen ringai2 years ago

Instructables now has a button to view all steps on one page, so this script is superfluous anyway.

mateddy n-regen2 years ago

I hate Instructable make this allstep as a button and charge to remove this click.

Especially when I can script it away.

zachninme (author) 10 years ago
Thanks Fungus for making the Instructable, smart!
ewilhelm10 years ago
If you don't quit writing code and generally hacking on the site, I'm going to have to offer you a job!
zachninme (author)  ewilhelm10 years ago
Haha
Well, don't worry, I wouldn't accept, as my JS is very poor. (although I am learning it so I can finally make the switch to Linux, ASP keeps me down)

Sorry if anything I do you consider "hacking", if you feel it is "bad", remove it immediately. I really won't take offense. (So far, I would only consider the HTML thing to be "bad" ) And I don't try to do things like hack the DB or anything, I'm not the kind of guy who would do that, and even if I was, what would I do with it? Look at your unpublished instructables? :P

Again, I'm not great at JS, so I would really like help fixing this line:
if (thisLink.href.match(/\?/i)) {
I would like it to say something along the lines of:
if ((thisLink.href.match(/\?/i)) && (thisLink.href.match("/id/"))) {

But I don't know if that "/id/" is parsed correctly. Again, my JS level right now is "combo-script-kiddie++", although it is getting better :P
I couldn't directly install the script from that link.

I created a new file with the same code and put it here: zachninme's All Steps

This code doesn't work for direct links to Instructables, just those from the directory lists.

For example, clicking on this tasty instructable won't do it.
Changing the included pages to "https://www.instructables.com/*" made it work even if it adds the "?ALLSTEPS" to everything.

Haven't seen a problem with that yet, but it's not ideal.
zachninme (author)  fungus amungus10 years ago
Well, the way it works is it looks for all links without any URL Postback info. Then it just adds the "?ALLSTEPS". So, technically, if the page isn't looking for it, it will just be ignored, and it won't hurt anybody. There are a couple of links on the explore page that don't have any PostBack, and aren't instructables, yet they handle it just fine. Thanks for mirroring that for me, the reason why you couldn't access is my internet was down, causing my server to disconnect. Should be fine now :-)
1-10 of 13Next »