Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Applying extensions

3 views
Skip to first unread message

JohnVee

unread,
Nov 29, 2006, 11:03:54 AM11/29/06
to
I am having a little trouble applying an extension according to the article
found here...

http://developer.mozilla.org/en/docs/Adding_Extensions_using_the_Windows_Registry

Has anyone ever attempted this procedure before and had it work? I have
followed the procedure and cannot get it to work. What I am doing is placing
the directory that contains my customized add-on into the "C:\program
files\mozilla\Mozilla Firefox 2.0\extensions" directory. The name of my
customized directory is pol...@mycompany.org. I then place a registry entry
as described in the article. It is supposed to automatically install the
extension the next time Firefox starts but it is not. I have even rebooted
to make sure.

The absolute path in the registry that I am using is a REG_SZ type named
like pol...@mycompany.org with a value of C:\Program Files\Mozilla\Mozilla
Firefox 2.0\extensions\pol...@mycompany.org. I have even tried including the
path to the install.rdf file and also to the .xpi file in the registry in
the absolute path in the registry.

If I drag the .xpi file over to the add-ons thru the firefox browser it
installs just fine. Could anyone help. Thanks.

I used the CCK to make my customized extension if that makes a difference


Tony Mechelynck

unread,
Nov 29, 2006, 12:40:01 PM11/29/06
to

Manually editing the Windows registry is a procedure with many pitfalls and
few safeguards. It should be avoided whenever there is another way to achieve
the same goal.

To install an addon (extension or theme) in Firefox, click the link to the
*.xpi or *.jar file; or if it is already downloaded, drag the extension file's
icon to the Extension Manager.


Best regards,
Tony.

JohnVee

unread,
Nov 29, 2006, 2:18:15 PM11/29/06
to

"Tony Mechelynck" <antoine.m...@belgacom.net> wrote in message
news:j46dncV4auZFWPDY...@mozilla.org...

Tony,

Thanks for the reply. I had a feeling that the registry entry was not the
way to go but I had to try someting. Here is what I am trying to accomplish.
The company I work for has a proxy server and has a group policy for IE, to
force IE to go thru the proxy server. A lot of people are downloading
Firefox and avoiding the proxy. Personally I dont like the proxy but we all
have to follow company policy. I have to find an automated way to get the
proxy setting into Firefox for about 400 computers.

If there was a way for me to drop an extension on a machine and have Firefox
pick up the settings for the proxy that would be great. We have a remote
desktop tool to drop the Mozilla Firefox extension on the computers but I
need Firefox to be able to pick the settings up without a visit to the desk
to drop the extension into the addon to get it to install.


Mike Shaver

unread,
Nov 29, 2006, 2:46:39 PM11/29/06
to JohnVee, dev-apps...@lists.mozilla.org
On 11/29/06, JohnVee <joh...@vee.com> wrote:
> I am having a little trouble applying an extension according to the article
> found here...
> http://developer.mozilla.org/en/docs/Adding_Extensions_using_the_Windows_Registry
>
> Has anyone ever attempted this procedure before and had it work? I have
> followed the procedure and cannot get it to work. What I am doing is placing
> the directory that contains my customized add-on into the "C:\program
> files\mozilla\Mozilla Firefox 2.0\extensions" directory. The name of my
> customized directory is pol...@mycompany.org. I then place a registry entry
> as described in the article. It is supposed to automatically install the
> extension the next time Firefox starts but it is not. I have even rebooted
> to make sure.

That _sounds_ like it should work. I believe that the Google Web
Accelerator or perhaps Google Desktop Search installs some extensions
that way, so you might take a look at what they put in the registry.
I'm sure it's something really small that we don't give a very good
diagnostic about.... :(

Mike

Simon Bünzli

unread,
Nov 29, 2006, 3:37:42 PM11/29/06
to
JohnVee schrieb am 29.11.06 17:03:

> Has anyone ever attempted this procedure before and had it work?

That's the way I develop almost all of my extensions - so it
definitively works, and quite well at that.

> I then place a registry entry as described in the article.

In the end, your registry entry should be located at
HKEY_CURRENT_USER\Software\Mozilla\Firefox\Extensions

(HKEY_LOCAL_MACHINE should work as well).

The REG_SZ with the extension's ID sounds fine, as does the full path to
your extension's folder (excluding a final backslash and any quotation
marks around the path).

Once it works, you might even get away writing a shell script to
automate the task of (un)registering an extension in the registry.

Unfortunately my version won't really help you much (unless you want to
install yet-another-scripting-language):

### Script to (un)register a Firefox extension in the Registry ###

import python

rdf = PScript.FSO.GetFile(PScript.Args[0] + "\\install.rdf")
id = file(rdf.Path,
"R").match(/id>\s*((?:\{[0-9a-fA-F-]{36}\}|[\w.+-]+@[\w.+-]+))\s*<\//)[1]
hkey = "HKCU\\Software\\Mozilla\\Firefox\\Extensions\\" + id
path = rdf.ParentFolder.Path

try:
if path != PScript.Shell.RegRead(hkey):
throw "Update to new path!"
PScript.Shell.RegDelete(hkey)
print "Extension %1 unregistered." % (id)
catch ex:
PScript.Shell.RegWrite(hkey, path)
print "Extension %1 registered." % (id)

### Script to (un)register a Firefox extension in the Registry ###

Cheers,
Simon

JohnVee

unread,
Nov 30, 2006, 9:32:32 AM11/30/06
to
"Simon Bünzli" <zen...@gmail.com> wrote in message
news:mamdnQvTNIUFcvDY...@mozilla.org...

Thank you to everyone who commented on this. What did work for me, well
almost work for me is putting the extension in
HKEY_CURRENT_USER\Software\Mozilla\Firefox\Extensions as opposed to where I
originally put it, HKEY_LOCAL_MACHINE\Software\Mozilla\Mozilla Firefox
2.0\Extensions.

I have Firefox 2.0 installed and compared the registry on my machine to the
documentation. I assumed that since the documentation was written before the
release of FF 2.0 I should modify the procedure in the registry to go to
HKEY_LOCAL_MACHINE\Software\Mozilla\Mozilla Firefox 2.0\Extensions as
opposed to HKEY_LOCAL_MACHINE\Software\Mozilla\Firefox\Extensions. . I know
when you assume things what happens.

But just so that everyone who reads this knows that putting the registry
setting in HKEY_LOCAL_MACHINE\Software\Mozilla\Firefox\Extensions still did
not work for me, I had to put it in
HKEY_CURRENT_USER\Software\Mozilla\Firefox\Extensions before it took.

I have one more thing to ask. I am no programmer and cannot write a lick of
script. I need to grey out the Connection Settings screen so the settings
cannot be changed. The configuration screen I am talking about is
Tools/Options/Advanced/Settings, Connection Settings. Can someone tell me
where to change this and possibly how to go about it? I am sure that if I
had to I could figure out how to do it, I just need a little direction to
get started.

Again, Thanks to all for the help.


Tony Mechelynck

unread,
Dec 1, 2006, 7:35:20 AM12/1/06
to
JohnVee wrote:
[...]

> I have one more thing to ask. I am no programmer and cannot write a lick of
> script. I need to grey out the Connection Settings screen so the settings
> cannot be changed. The configuration screen I am talking about is
> Tools/Options/Advanced/Settings, Connection Settings. Can someone tell me
> where to change this and possibly how to go about it? I am sure that if I
> had to I could figure out how to do it, I just need a little direction to
> get started.
>
> Again, Thanks to all for the help.

What about tackling the matter at the hardware level, so that no one within
your company can reach the outside without going through a gateway (a
dedicated machine, the only one with an outside Internet connection, and to
which only the system administrator would have access)?


Best regards,
Tony.

JohnVee

unread,
Dec 1, 2006, 11:38:02 AM12/1/06
to
"Tony Mechelynck" <antoine.m...@belgacom.net> wrote in message
news:r9WdneJA3OXAvO3Y...@mozilla.org...

Tony,

That would make too much sense. I do not work for that group that would
impliment that. I work on the Desktop system administration and software
distribution side of the house. The powers that be decided that for what
ever reason they are not going that way. Maybe sometime in the future but
not now. This is the solution that is to be implimented. I know of other
companies that do it the way you indicated, in fact other divisions of this
company, outside of the U.S do it that way but we need to be different.

Does anyone know how to grey out particular portions of the settings so they
cannot be changed? I really would like to know.


Mike Shaver

unread,
Dec 1, 2006, 12:22:22 PM12/1/06
to JohnVee, dev-apps...@lists.mozilla.org
On 12/1/06, JohnVee <joh...@vee.com> wrote:
> Does anyone know how to grey out particular portions of the settings so they
> cannot be changed? I really would like to know.

I believe that the CCK has provisions for locking preferences, but I
don't know the details.

Mike

Steffen Wilberg

unread,
Dec 2, 2006, 4:00:25 PM12/2/06
to
> Does anyone know how to grey out particular portions of the settings so they
> cannot be changed? I really would like to know.

Have a look at this doc:
http://kb.mozillazine.org/Lock_Prefs

Steffen

JohnVee

unread,
Dec 5, 2006, 12:47:19 PM12/5/06
to

"Steffen Wilberg" <steffen...@nospam.web.de> wrote in message
news:zbWdnZgBO7jxdOzY...@mozilla.org...

Thank You to all, this is exactly what I was looking for. Took a minute to
figure out the syntax for multiple lines in the .cfg file. Once that was
done I was good to go. Once again, thanks to all.


0 new messages