Extension Idea: AutoClick - The Automatic Link Clicker

Talk about add-ons and extension development.
Locked
User avatar
pandaking
Posts: 30
Joined: July 8th, 2006, 6:25 pm

Extension Idea: AutoClick - The Automatic Link Clicker

Post by pandaking »

In my opinion for a very useful firefox extension which I am certainly in the need for and I think many others could make great use for.

The idea
Links that you click a lot can be remembered, and when found on a page they get automatically clicked.

So for instance, after you make a post on a forum you need click continue on the confirmation message. If you do this a lot, you could right click the link and select AutoClick
Next time the page loaded with that continue button it would automatically click it and take you to the next page.

I personally really want it for managing banning users on a phpbb forum where I am constantly clicking "back to ban control" after banning someone.
But as you can see there are numerous possibilities why someone might want this.
Could be better implemented on greasemonkey?

Just my idea...
User avatar
pandaking
Posts: 30
Joined: July 8th, 2006, 6:25 pm

Post by pandaking »

Anyone?

For me it would also be really helpful with natwest.com - every time I visit it, I click "log in" ...
einare
Posts: 159
Joined: October 22nd, 2006, 1:16 pm
Location: Iceland
Contact:

Post by einare »

I kinda like the idea. I'd probably call it Auto Redirect instead. A cool feature would be to able to specify from and to url with a regular expression, e.g.

http://example.com/article?id=1234
could be redirected to http://example.com/someotherpage?id=1234

by specifiying that http://example.com/article?id=(\d+)
should be redirected to http://example.com/someotherpage?id=$1

I'll look into it but it'll probably take a while.
Try my javascript card games, Hearts, Idiot and Crazy Eights
User avatar
pandaking
Posts: 30
Joined: July 8th, 2006, 6:25 pm

Post by pandaking »

That would be a good feature yes :)

Wow, that's awesome you want to give it a go. I think it would be a very highly used addon.

Nice one ^^
User avatar
pandaking
Posts: 30
Joined: July 8th, 2006, 6:25 pm

Post by pandaking »

Hows it coming on?
einare
Posts: 159
Joined: October 22nd, 2006, 1:16 pm
Location: Iceland
Contact:

Post by einare »

I started it but then go swamped with work so I haven't been able to finish it. What is already there:

1. Ability to right click and select 'Add current url to redirector'. If you click on a link it'll say 'Add link url to Redirector'. This opens up a box with the current url in the 'Pattern' box and the link url in the 'Redirect to' box. You can use wildcards in the pattern, e.g. http://www.example.com* will redirect all pages that start with http://www.example.com. There's also a checkbox that says 'Only if link exists on page', which means just that, if you set foo.com to redirect to bar.com, but foo.com doesn't contain a link to bar.com then there'll be no redirect. This works similar to your original idea, which was to click links.

2. The redirects work :)


What doesn't work: (a much longer list...)

1. The CRUD stuff for updating and deleting redirects doesn't work yet.
2. You can only access the redirect list through about:config, they key is called extensions.redirector.redirects . It's a simple javascript object, so if you know javascript you'll be able to figure it out if you want to delete something.
3. No regex support yet.
4. Adding new urls doesn't work between windows. e.g. if you have two firefox windows open, and add a new url in one of them, it won't work in the other one rigth away, just the one you added it in. On next restart it'll work in all windows.

So, as you can see, there's quite a bit of stuff left :). But if you wanna test the extremely raw alpha version you can get it at http://einaregilsson.com/downloads/redirector-alpha.xpi . I'll try to finish the rest soon.
Try my javascript card games, Hearts, Idiot and Crazy Eights
einare
Posts: 159
Joined: October 22nd, 2006, 1:16 pm
Location: Iceland
Contact:

Post by einare »

Hmm, for some reason clicking on that link doesn't work. Try copying it and paste-ing in your address bar and then youll get the 'download extension' dialog
Try my javascript card games, Hearts, Idiot and Crazy Eights
User avatar
pandaking
Posts: 30
Joined: July 8th, 2006, 6:25 pm

Post by pandaking »

Aweseome! You bloody legend!
It's working great :D And that link worked perfectly for me just clicking it :P

I clicked tried clicking tools, addons, selected redirector, and then hit options.
The whole thing just froze and died. But You probably haven't got to that bit yet.

I can't wait to being able view and delete existing redirects! ZOMG you are soooo amazing!

Also, I was thing I small little icon like greasemonkey has in the statusbar which just like greasemonkey when you click it it disables the rediector.

Great job, I so wasn't expecting you to have done much xD
einare
Posts: 159
Joined: October 22nd, 2006, 1:16 pm
Location: Iceland
Contact:

Post by einare »

Well, I finally got off my ass and finished this thing, almost :)

The new version has all functionality that will be in the final version.

1. Add current url / add link url in right click context menu
2. Both wildcard and regex patterns, regex supports capturing parantheses
3. Only redirect if link exists option
4. Can disable Redirector with a statusbar icon.
5. Can edit and delete redirects, go to Tools->Redirector, or addons window and Options button.

It's version 0.9.1 as of now, since it's almost complete. After I fix the look (it's quite ugly :) ) I'll bump it up to 1.0. You can get it at https://addons.mozilla.org/en-US/firefox/addon/5064 , you'll need to be a registered user since it's in the sandbox. ONE IMPORTANT THING: If you like it, please leave a review there, it'll help to get it out of the "#%&# sandbox. Thanks!

Oh, one other thing. Before you install this new version, goto about config, find the extensions.redirector.redirects key, and set it to [] . The reason you need to do this is that I made some changes from the alpha version and if you have the old format it might screw it all up. You'll need to enter your redirects again.

Enjoy.
-einare
einare
Posts: 159
Joined: October 22nd, 2006, 1:16 pm
Location: Iceland
Contact:

Post by einare »

This can now also be found on my own page, http://tech.einaregilsson.com/projects/redirector/ for those who don't want to login to the sandbox.
Try my javascript card games, Hearts, Idiot and Crazy Eights
User avatar
pandaking
Posts: 30
Joined: July 8th, 2006, 6:25 pm

Post by pandaking »

Just wanted to say thanks xD
einare
Posts: 159
Joined: October 22nd, 2006, 1:16 pm
Location: Iceland
Contact:

Post by einare »

Version 1.0 just released. New Features:

1. Instant redirects, no longer waits for the original page to load
2. Supports xpath queries to create redirect urls
3. Supports relative urls as redirect urls.

http://tech.einaregilsson.com/projects/redirector/
https://addons.mozilla.org/en-US/firefox/addon/5064
Try my javascript card games, Hearts, Idiot and Crazy Eights
Locked