Firefox:Dive Into Greasemonkey/6.4. Compiling your user script into an extension
Mozilla中文Wiki
您的位置:Dive Into Greasemonkey → 高级话题 → 把您的用户脚本编译为扩展
6.4. 把您的用户脚本编译为扩展
想让您的用户脚本“成长”到超出Greasemonkey的框架吗?您的用户脚本需要接触Javascript特权函数,本地文件,或者其它只有完全的浏览器扩展才具有的Firefox特性?您能把你的脚本转换为完全的XPI,仅仅需要几次点击。感谢Adrian Holovaty令人惊奇的Greasemonkey编译器!
访问Butler用户脚本的源代码 (http://diveintomark.org/projects/butler/butler.user.js)。从菜单开始,选择“编辑” → 全选(Ctrl-A),复制全部源代码到剪贴板。
访问Greasemonkey编译器 (http://www.letitblog.com/greasemonkey-compiler/)。
在“Javascript”栏中,菜单中,选择“编辑” →“粘贴”(Ctrl-V),粘贴 Butler 用户脚本的源代码。
在作者(Creator)栏中,填写 "Mark Pilgrim"
在版本(Version)栏中,填写 Butler 的当前版本(在此文完成是0.3版,但是请查看脚本的元数据以确认真实版本。
打开一个新窗口或者标签,访问GUID发生器,产生一个随机的GUID。把这个GUID复制到剪贴板,包含大括号。
回到“Greasemonkey编译器”的页面。在“GUID”栏粘贴刚才从GUID发生器上获得的GUID。
在主页(Homepage)栏,填写 http://diveintomark.org/projects/butler/ 。
点击创建Firefox扩展。Firefox会弹出一个对话框,标题为“Opening butler.xpi”(打开 butler.xpi),选择保存到磁盘,并且选择一个目录
待续……
Strict Standards: Non-static method Namespace::getUser() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 510
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::isTalk() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1367
Strict Standards: Non-static method Namespace::getTalk() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1387
Strict Standards: Non-static method Namespace::isTalk() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 99
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1437
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1439
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1439
Strict Standards: Non-static method Namespace::getImage() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1505
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getSpecial() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/languages/Language.php on line 1456
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getSpecial() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/languages/Language.php on line 1456
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getUser() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 775
Strict Standards: Non-static method Namespace::getTalk() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 776
Strict Standards: Non-static method Namespace::getUser() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 776
Strict Standards: Non-static method Namespace::isTalk() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 99
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getSpecial() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/languages/Language.php on line 1456
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Title::makeTitle() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 718
Strict Standards: Non-static method Title::makeName() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 138
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be assigned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 718
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 900
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getSpecial() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/languages/Language.php on line 1456
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getSpecial() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/languages/Language.php on line 1456
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getUser() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 510
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::isTalk() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1367
Strict Standards: Non-static method Namespace::getTalk() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1387
Strict Standards: Non-static method Namespace::isTalk() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 99
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1437
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1439
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1439
Strict Standards: Non-static method Namespace::getImage() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1505
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getSpecial() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/languages/Language.php on line 1456
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getSpecial() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/languages/Language.php on line 1456
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getUser() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1023
Strict Standards: Non-static method Namespace::getTalk() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1024
Strict Standards: Non-static method Namespace::getUser() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1024
Strict Standards: Non-static method Namespace::isTalk() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 99
Strict Standards: Non-static method Namespace::getSpecial() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/languages/Language.php on line 1456
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1450
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Non-static method Title::newFromText() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452
Strict Standards: Non-static method Namespace::getCanonicalIndex() should not be called statically, assuming $this from incompatible context in /home/mozcn/html/mediawiki-1.3.18/includes/Title.php on line 695
Notice: Only variable references should be returned by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Namespace.php on line 138
Strict Standards: Only variables should be passed by reference in /home/mozcn/html/mediawiki-1.3.18/includes/Skin.php on line 1452

![[首页]](/stylesheets/images/wiki.png)