How can I get a printable list of the web sites in a tab showing both the name of the site and it's location?
I use tab groups for specific projects and would like to print/save a list of the websites used on each project. Using the list function on a tab group produces a list of the web-sites which can be printed/saved via PrtSc and Word. How can the web-site addresses be included? With this list available I would then close the tabs.
Toate răspunsurile (2)
Someone might have created an add-on for this, although I didn't find one in a search.
Could I suggest this workaround for now:
(1) Use the Bookmark All Tabs feature (right-click a tab when your tab group is displayed) to save all tabs to a new folder on the bookmarks menu. Some tips in the "How do I bookmark all of my open tabs?" section of this article: Bookmarks in Firefox.
(2) Export bookmarks to an HTML file. Unfortunately, this will be all bookmarks, not just the ones you want, but hang in there. This article has the steps: Export Firefox bookmarks to an HTML file to back up or transfer bookmarks.
(3) Open the exported HTML file in Firefox or your favorite WP program. Now you can either:
(A) Copy/paste the live links for your tab group into your preferred form of archival storage. Or
(B) Print (e.g., select the relevant bookmarks and use the Print Selection feature). However, in order to show the URLs, you need to hack the page a little bit.
(i) In Firefox, you can run a little script in the Web Console on the bookmarks page. Press Ctrl+Shift+k to open the web console. Copy the following line of script, then paste it next to the caret (">") in the web console and press Enter. The URLs should appear after the links.
for(var i=0; i<document.links.length; i++) {document.links[i].parentNode.appendChild(document.createTextNode(' ['+document.links[i].href+']'))}
(ii) In Word, there probably is a macro to split the hyperlink fields into the display text and URL. If Word is your preferred tool, I'll see whether I can write one.
Here is some basic code that you can run in the error console or browser console to get a list of tabs in the current window.
var {classes:Cc,interfaces:Ci} = Components; var wm = Cc["@mozilla.org/appshell/window-mediator;1"].getService(Ci.nsIWindowMediator); var mW = wm.getMostRecentWindow("navigator:browser"); var gB = mW.gBrowser; var l = gB.mPanelContainer.childNodes.length; var mT = gB.mTabContainer.childNodes; var i,t=[]; for(var i=0;i<l;i++){ H = gB.getBrowserAtIndex(i).contentDocument.location; L = mT[i].getAttribute('label'); t.push('['+(i+1)+'] '+H+' «'+L+'»'); } var dataURI = 'data:text/html;charset=utf-8,<html><body>'+t.join('<br>').replace(/#/g,'%23')+'</body></html>'; var tab = gB.addTab(dataURI); gB.selectedTab = tab;
The sessionstore.js file also stores a list of open tabs that can be processed by a script.
See this mozillaZine forum thread for some example code:
Modificat în