Personal Development for Smart People Forums

Personal Development for Smart PeopleTM Forums

 

Go Back   Personal Development for Smart People Forums > Personal Development > Technology & Technical Skills

Notices

Technology & Technical Skills Computer skills, hardware, software, internet topics, gadgets, programming

Reply
 
Thread Tools Display Modes
Old 11-08-2006, 07:31 AM   #1 (permalink)
Member
 
Join Date: Nov 2006
Posts: 47
tomjen is on a distinguished road
Default Prevent links from opening in new windows (Firefox, Greasemonkey)

I got tired of having links open in new windows, so I developed this Greasemonkey script. Hope your find it usefull:

----cut here----

// ==UserScript==
// @name Window fixer
// @description Prevent opening of links in new windows, since it better options are now possible.
// @include http://www.stevepavlina.com/*
// @include http://stevepavlina.com/*
// ==/UserScript==
var links;
links = document.getElementsByTagName('a');
for(i=0;i<links.length;i++)
{
links[i].setAttribute('target','');
}

----cut here----
tomjen is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-08-2006, 07:34 AM   #2 (permalink)
Family Member
 
Join Date: Nov 2006
Location: Seattle, Washington, USA
Posts: 3,977
Michael Chui has much to be proud ofMichael Chui has much to be proud ofMichael Chui has much to be proud ofMichael Chui has much to be proud ofMichael Chui has much to be proud ofMichael Chui has much to be proud ofMichael Chui has much to be proud ofMichael Chui has much to be proud ofMichael Chui has much to be proud of
Default

On my old computer (I haven't installed everything onto this one yet), I had TargetAlert, which would inform me if the link I was hovering over would open a new window. I usually switched over to the scroll button at that point to open up a new tab instead. Firefox 2 seems to do this automatically, though that might be a preference I haven't noticed yet.
Michael Chui is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-08-2006, 12:35 PM   #3 (permalink)
Senior Member
 
Join Date: Nov 2006
Location: Illinois
Posts: 149
TechnoGuyRob is on a distinguished road
Default

The exact same thing can be done in Firefox 2.0 (but I know I had it enabled in Firefox 1.5 as well, don't know the config option) by going to:

Tools -> Options -> Tabs -> open pages in a new tab

Plus, this will open any javascript-generated pop-ups in new tabs as well.
TechnoGuyRob is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off



All times are GMT. The time now is 12:14 PM.


Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Copyright © 2010 by Pavlina LLC