Customize Copy URL+

As of version 1.1, Copy URL+ allows you to add your own menu entries. By simply adding a couple of entries to the user.js file, you can create countless custom entries.
For each menu entry you need to have in addition to the standard three, you will need to add two lines to the user.js file situated in your Mozilla/Firefox profile folder.

I recomend that you use the ChromEdit extension, to modify this file (thank Chad Cloman for the tip).
Edit userChrome.css, userContent.css or user.js, without the hassle of finding your profile.
However, if you want to do it by yourself, please know that the location of the user.js file is dependent of your operating system and it's per user. Since it's a user specific file, on a lot of systems it might not originally exist, so you'll have to create it.
To locate the proper folder read below:
  1. On Windows XP/2000, the path is usually %AppData%\Mozilla\Firefox\Profiles\\, where xxx is a random string of 3 characters. Just browse to C:\Documents and Settings\[User Name]\Application Data\Mozilla\Firefox\Profiles\ and the rest should be obvious.
  2. On Windows 95/98/Me, the path is usually C:\WINDOWS\Application Data\Mozilla\Firefox\Profiles\\
  3. On Linux, the path is usually ~/.mozilla/firefox/
  4. On MacOS X, the path is usually ~/Library/Application Support/Firefox/Profiles/
Quick Tip from David McRitchie (see more here):
Check out this excellent page on more FireFox customizations:
Firefox Help: Editing Configuration Files and Firefox Help: Tips & Tricks

These lines would like the following:
user_pref('copyurlplus.menus.1.label', 'Copy URL + Title + Sel (HREF + Tooltip)');
user_pref('copyurlplus.menus.1.copy', '<a href="%URL%" title="%SEL%">%TITLE%</a>');

In this example, the first line, the .label line, defines the label of the new menu entry. The second one defines the format of the text to be copied to clipboard when choosing this menu entry. The format of the entry is copyurlplus.menus.<i>.label (or .copy), where i is an sequential number, starting at 1. When creating multiple entries, make sure you don't skip any numbers as Copy URL+ will stop adding entries to the menu when it detects a gap (e.g. 1,2,4 will only add entries 1 and 2).

The markup you can use inside the string is:

Here are some examples of custom entries for your user.js file. Add as many as you want, but don't forget to increment the number!

Got more? Send them along and I'll be happy to add them!

The copyurlplus project can be contacted through the mailing list or the member list.
Copyright © 2000-2014. All rights reserved. Terms of Use & Privacy Policy.