<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>某人的栖息地 &#187; firebug</title>
	<atom:link href="http://www.ooso.net/tag/firebug/feed" rel="self" type="application/rss+xml" />
	<link>http://www.ooso.net</link>
	<description>Linux + Apache + Mysql + Php + Flash</description>
	<lastBuildDate>Thu, 11 Mar 2010 17:54:31 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>用firebug来调试actionscript</title>
		<link>http://www.ooso.net/archives/442</link>
		<comments>http://www.ooso.net/archives/442#comments</comments>
		<pubDate>Thu, 03 Jul 2008 13:23:17 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[flash]]></category>
		<category><![CDATA[actionscript]]></category>
		<category><![CDATA[firebug]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/442</guid>
		<description><![CDATA[往常调试actionscript，是用的trace，在flash debug player里头输出变量内容。今天看到的方法比较有趣，是利用javascript在firebug中输出as的调试信息。
用firebug调试as的基本原理
PLAIN TEXT
CODE:

				<span class="readmore"><a href="http://www.ooso.net/archives/442" title="用firebug来调试actionscript">阅读全文（320字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>往常调试actionscript，是用的trace，在flash debug player里头输出变量内容。今天看到的方法比较有趣，是利用javascript在<a href="http://www.ooso.net/index.php/archives/294">firebug</a>中输出as的调试信息。</p>
<h3>用firebug调试as的基本原理</h3>
<div class="igBar"><span id="lcode-2"><a href="#" onclick="javascript:showCodeTxt('code-2'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-2">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">ExternalInterface.<span style="">call</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">'console.log'</span>, <span style="color:#CC0000;">"string is [%s]"</span>,&nbsp; <span style="color:#CC0000;">"abcde"</span><span style="color:#006600; font-weight:bold;">&#41;</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p>
利用as的ExternalInterface和js交互，然后调用firebug的console.log，将as的变量输出到控制台，这样也能达到调试的目的。</p>
<p>当然，要使用firebug，前提当然是你使用的firefox浏览器。如果是ie，那么只好使用alert弹出信息。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/442/feed</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>firebug已经提供中文界面</title>
		<link>http://www.ooso.net/archives/437</link>
		<comments>http://www.ooso.net/archives/437#comments</comments>
		<pubDate>Sun, 29 Jun 2008 02:25:52 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[firebug]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=437</guid>
		<description><![CDATA[一句话，firebug 1.2 beta4已经开始提供中文本地化界面，见图

图中还能看出，从前的“No Allowed-sites/Disable for Site”选项已经不再生效，只对单个站点起作用
]]></description>
			<content:encoded><![CDATA[<p>一句话，<a href="https://addons.mozilla.org/firefox/addon/1843">firebug 1.2 beta4</a>已经开始提供中文本地化界面，见图</p>
<p><a href="http://www.ooso.net/index.php/archives/294"><img src="http://www.ooso.net/wp-content/uploads/2008/06/firebug12.gif" alt="" title="firebug12" width="456" height="225" class="alignnone size-full wp-image-438" /></a></p>
<p>图中还能看出，从前的“No Allowed-sites/Disable for Site”选项已经不再生效，只对单个站点起作用</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/437/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>FirePHP &#8212; php版的firebug</title>
		<link>http://www.ooso.net/archives/424</link>
		<comments>http://www.ooso.net/archives/424#comments</comments>
		<pubDate>Tue, 17 Jun 2008 07:26:45 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[debug]]></category>
		<category><![CDATA[firebug]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=424</guid>
		<description><![CDATA[在friendfeed上找到的了这个名为FirePHP的Firefox插件，是基于Firebug的一个扩展，可以用来在Firebug的console中方便的输出php的调试信息又不影响php程序的正常运行。实际上这东东出来的时间也不短了，只是以前没试用过，现在把玩了一会也挺有趣。附图一张：

FirePHP包含两个部分


				<span class="readmore"><a href="http://www.ooso.net/archives/424" title="FirePHP &#8212; php版的firebug">阅读全文（445字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>在<a href="http://friendfeed.com">friendfeed</a>上找到的了这个名为<a href=" http://www.firephp.org/">FirePHP</a>的Firefox插件，是基于<a href="http://www.ooso.net/index.php/archives/294">Firebug</a>的一个扩展，可以用来在Firebug的console中方便的输出php的调试信息又不影响php程序的正常运行。实际上这东东出来的时间也不短了，只是以前没试用过，现在把玩了一会也挺有趣。附图一张：</p>
<p><img src="http://www.firephp.org/images/Screenshots/Sample1b.png" alt="firephp" /></p>
<h3>FirePHP包含两个部分</h3>
<ul>
<li><a href="https://addons.mozilla.org/en-US/firefox/addon/6149">firefox扩展 </a></li>
<li><a href="http://www.firephp.org/DownloadRelease/FirePHPLibrary-FirePHPCore-0.0.2">php程序库 </a></li>
</ul>
<p>FirePHP的php调试信息都是通过在http头里面添加X-FirePHP-Data信息串来标识，不会直接输出到页面上，这样也就避免对php正常输出产生影响。可以输出的调试信息类型如下:</p>
<ul>
<li>正常的调试字符串，类型有LOG,INFO,WARN,ERROR几种</li>
<li>数组array</li>
<li>object</li>
<li>异常Exception</li>
<li>SQL返回数据</li>
<li>http header</li>
</ul>
<p>如果你像我一样使用的是firefox 3，那么可以<a href="http://www.firephp.org/DownloadRelease/FirePHP-FirefoxExtension-0.1.0.1">点这里下载安装FirePHP  0.1.0.1</a></p>
<p>这个版本只适用于php5，再贴个<a href="http://www.live-my-life-with-yuyi.com/blog/archives/354">网友自力更生的简化版</a>，但是功能上就弱多了，而且是通过js来输出调试信息，实用性也不强。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/424/feed</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>用greasemonkey生成土豆的豆单下载清单</title>
		<link>http://www.ooso.net/archives/400</link>
		<comments>http://www.ooso.net/archives/400#comments</comments>
		<pubDate>Sun, 18 May 2008 23:51:35 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[firebug]]></category>
		<category><![CDATA[flv]]></category>
		<category><![CDATA[greasemonkey]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[土豆]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=400</guid>
		<description><![CDATA[前一阵忙里偷闲上土豆补看了一小段“机动战士高达Seed”，但是我这的网络有点垃圾，看的断断续续，十分不爽，折腾了一下午也就看了两三段。一怒之下，写了个greasemonkey脚本，生成土豆的豆单下载清单，配合快车批量下载，速度不要太快~
使用方法

首先你需要使用firefox浏览器

				<span class="readmore"><a href="http://www.ooso.net/archives/400" title="用greasemonkey生成土豆的豆单下载清单">阅读全文（397字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>前一阵忙里偷闲上土豆补看了一小段“机动战士高达Seed”，但是我这的网络有点垃圾，看的断断续续，十分不爽，折腾了一下午也就看了两三段。一怒之下，写了个<a href="/index.php?tag=greasemonkey">greasemonkey</a>脚本，生成土豆的豆单下载清单，配合快车批量下载，速度不要太快~</p>
<h3>使用方法</h3>
<ul>
<li>首先你需要使用<a href="http://www.firefox.com">firefox浏览器</a></li>
<li>安装firefox的<a href="https://addons.mozilla.org/zh-CN/firefox/addon/748">greasemonkey插件</a></li>
<li>安装<a href="https://addons.mozilla.org/zh-CN/firefox/addon/1843">firebug插件</a>并重启firefox</li>
<li>安装<a href="http://customcode.googlecode.com/files/TudouDownloadList.user.js">TudouDownloadList</a>，如果greasemonkey安装正确的话，点击之前的链接应该会弹出一个安装框。</li>
<li>去访问土豆的豆单播放页，比如<a href="http://www.tudou.com/playlist/playindex.do?lid=676944">机动战士高达seed</a>，呼出firebug(按F12就可以了)，你会看到firebug的控制台里生成了一批flv文件的列表</li>
<li>复制这批flv文件的url，保存为后缀为.lst的文件</li>
<li>使用flashget导入列表即可批量下载土豆豆单了</li>
</ul>
<h3>补充</h3>
<p>为了能使用快车正常下载，你需要把下图所示的小勾去掉。<br />
<img src="http://www.ooso.net/wp-content/uploads/2008/05/flashget.jpg" alt="flashget" title="flashget"  /></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/400/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>安装firefox 3以后</title>
		<link>http://www.ooso.net/archives/398</link>
		<comments>http://www.ooso.net/archives/398#comments</comments>
		<pubDate>Thu, 15 May 2008 13:20:11 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[firebug]]></category>

		<guid isPermaLink="false">http://www.ooso.net/?p=398</guid>
		<description><![CDATA[前两天在网上看到有firefox 3 rc1下载，于是忍不住也下载了一个装上（看来我还真是一个习惯做小白鼠的人）。
刚装上，事就来了。首先是所有的firefox插件全部报废，版本不兼容。上网查查，最简单的办法就是禁用firefox的插件版本检查功能。

在地址栏里敲about:config，回车

				<span class="readmore"><a href="http://www.ooso.net/archives/398" title="安装firefox 3以后">阅读全文（635字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>前两天在网上看到有firefox 3 rc1下载，于是忍不住也下载了一个装上（看来我还真是一个习惯做小白鼠的人）。</p>
<p>刚装上，事就来了。首先是所有的<a href="/index.php?tag=firefox">firefox</a>插件全部报废，版本不兼容。上网查查，最简单的办法就是禁用firefox的插件版本检查功能。</p>
<ul>
<li>在地址栏里敲about:config，回车</li>
<li>修改extensions.checkCompatibility的值为false，如果没有这一项就新增一个布尔值</li>
<li>重启firefox</li>
</ul>
<p>这样，所有的插件也能使了。这让我很开心，因为第一感觉是firefox 3的执行速度比较快，不知道是不是心理因素，总之流畅。第二个就是新的地址栏很酷，据说是什么智能地址栏，敲几个网址，地址栏里头不仅显示地址，连标题和图标都给你列的一清二楚，方便是方便呀，可我还是费了些功夫才适应下来。</p>
<p>感觉很爽。这种感觉持续了两天，两天后我开始要写点javascript了，于是我习惯召唤出firebug来协同作战，这下新的噩梦来了。firebug的console.log完全没法使用（我装的firebug是1.1 beta），而且我还自作聪明的继续小白鼠一把——安装了firebug 1.2 alpha，虽然console可以用了，但是jquery的$函数功能无法使用，鼓捣了一晚上，愣是没能写出几行javascript。</p>
<p>又回到了firefox 2，踏实。</p>
<h3>Update</h3>
<p>升级到了firefox 3正式版，很稳定，速度也很快。如果是<a href="https://addons.mozilla.org/zh-CN/firefox/addon/1843">需要能在firefox 3下使用的firebug，请点这里</a>。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/398/feed</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>firebug现在已经可以支持firefox 3</title>
		<link>http://www.ooso.net/archives/383</link>
		<comments>http://www.ooso.net/archives/383#comments</comments>
		<pubDate>Fri, 29 Feb 2008 00:59:56 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[firebug]]></category>
		<category><![CDATA[插件]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/383</guid>
		<description><![CDATA[最新的firebug 1.1 beta，可以在firefox 3 beta下运行。现在即便为了尝鲜升级到firefox 3，也可以享受firebug的便利。
firebug 1.1 beta下载
]]></description>
			<content:encoded><![CDATA[<p>最新的firebug 1.1 beta，可以在firefox 3 beta下运行。现在即便为了尝鲜升级到firefox 3，也可以享受<a href="/?tag=firebug">firebug</a>的便利。</p>
<p><a href="http://getfirebug.com/releases/index.html">firebug 1.1 beta下载</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/383/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>使用firebug的补充</title>
		<link>http://www.ooso.net/archives/381</link>
		<comments>http://www.ooso.net/archives/381#comments</comments>
		<pubDate>Fri, 25 Jan 2008 10:14:56 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[firebug]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/381</guid>
		<description><![CDATA[这里是最近使用firebug的一个补充记录，以后也会不断更新。
列出一个object的所有内容
在console上使用命令
PLAIN TEXT

				<span class="readmore"><a href="http://www.ooso.net/archives/381" title="使用firebug的补充">阅读全文（391字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>这里是最近使用<a href="/?tag=firebug">firebug</a>的一个补充记录，以后也会不断更新。</p>
<h2>列出一个object的所有内容</h2>
<p>在console上使用命令</p>
<div class="igBar"><span id="lcode-6"><a href="#" onclick="javascript:showCodeTxt('code-6'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-6">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">console.<span style="">dir</span><span style="color:#006600; font-weight:bold;">&#40;</span>obj<span style="color:#006600; font-weight:bold;">&#41;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>可以查看一个object所包含的方法，属性	</p>
<h2>firebug提供的console对象有哪些方法</h2>
<p>用dir方法看一下console本身即可</p>
<div class="igBar"><span id="lcode-7"><a href="#" onclick="javascript:showCodeTxt('code-7'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-7">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">console.<span style="">dir</span><span style="color:#006600; font-weight:bold;">&#40;</span>console<span style="color:#006600; font-weight:bold;">&#41;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<h2>console用法列表</h2>
<div class="igBar"><span id="lcode-8"><a href="#" onclick="javascript:showCodeTxt('code-8'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-8">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">console.<span style="">time</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">"test timer"</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">console.<span style="">log</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">"Hello from "</span>,document.<span style="">title</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">console.<span style="">info</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">"This is info"</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">console.<span style="">warn</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">"This is warning"</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">console.<span style="">error</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">"This is error"</span><span style="color:#006600; font-weight:bold;">&#41;</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">console.<span style="">timeEnd</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">"test timer"</span><span style="color:#006600; font-weight:bold;">&#41;</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/381/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>在ie下使用firebug</title>
		<link>http://www.ooso.net/archives/328</link>
		<comments>http://www.ooso.net/archives/328#comments</comments>
		<pubDate>Sun, 17 Jun 2007 01:06:16 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[firebug]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/328</guid>
		<description><![CDATA[在ie下，firebug只提供了一个简化版的firebug lite，这个version是一个单独的js，你需要在每一个页面中嵌入一段firebug.js来激活firebug，有些不便。这里给出的解决方案是利用ie的bookmarklet来快速呼出firebug。
安装步骤

下载firebug.js到你自己的服务器这么做之后你就不必担心某天我会对你实施跨站攻击了~~

				<span class="readmore"><a href="http://www.ooso.net/archives/328" title="在ie下使用firebug">阅读全文（419字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>在ie下，<a href="http://www.ooso.net/index.php/archives/294">firebug</a>只提供了一个简化版的firebug lite，这个version是一个单独的js，你需要在每一个页面中嵌入一段firebug.js来激活firebug，有些不便。这里给出的解决方案是利用ie的bookmarklet来快速呼出<a href="index.php?tag=firebug">firebug</a>。</p>
<h1>安装步骤</h1>
<ul>
<li>下载firebug.js到你自己的服务器<br />这么做之后你就不必担心某天我会对你实施跨站攻击了~~</li>
<li>安装bookmarklet，把下面的链接拖动ie的工具条上，如果是ie 7，这个链接貌似拖拽不了，可能是基于安全考虑，但是你可以右键 -&gt; 添加到收藏夹 -&gt; 加到“链接”分类下<br />
<h2><a href="javascript:var%20h=document.getElementsByTagName('html');h[0].setAttribute('debug',%20'true');if%20(!document.getElementById('_fb'))%20{%20var%20q=document.createElement('script');q.setAttribute('id',%20'_fb');q.setAttribute('src',%20'http://www.ooso.net/demo/firebug.js');document.getElementsByTagName('body')[0].appendChild(q);void(q);}else{void(window.console.open());}">Firebug Bookmarklet</a></h2>
</li>
<li>将刚才bookmarklet中的firebug.js和firebug.css替换成你自己服务器上的url</li>
</ul>
<h1>使用</h1>
<p>使用其实很简单，在需要firebug的页面上，点击ie工具条上的Firebug Bookmarklet就可以了</p>
<h1>原文</h1>
<p><a href="http://remysharp.com/2007/03/13/firebug-in-ie-for-any-web-site/">Firebug in IE for *any* web site</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/328/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>初识Firebug 全文 &#8212; firebug的使用</title>
		<link>http://www.ooso.net/archives/294</link>
		<comments>http://www.ooso.net/archives/294#comments</comments>
		<pubDate>Tue, 15 May 2007 01:54:03 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[firebug]]></category>
		<category><![CDATA[插件]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/294</guid>
		<description><![CDATA[本文最初发表《程序员》杂志第三期，现将全文贴上，内容已经过编辑修饰了很多:)
什么是Firebug
从事了数年的Web开发工作，越来越觉得现在对WEB开发有了更高的要求。要写出漂亮的HTML代码；要编写精致的CSS样式表展示每个页面模块；要调试javascript给页面增加一些更活泼的要素；要使用Ajax给用户带来更好的体验。一个优秀的WEB开发人员需要顾及更多层面，才能交出一份同样优秀的作业。为帮助广大正处于Web2.0洪流中的开发人员，在这里为大家介绍一款轻巧灵活的辅助开发工具。
Firebug是Firefox下的一款开发类插件，现属于Firefox的五星级强力推荐插件之一。它集HTML查看和编辑、Javascript控制台、网络状况监视器于一体，是开发JavaScript、CSS、HTML和Ajax的得力助手。Firebug如同一把精巧的瑞士军刀，从各个不同的角度剖析Web页面内部的细节层面，给Web开发者带来很大的便利。这是一款让人爱不释手的插件，如果你以前没有接触过它，也许在阅读本文之后，会有一试的欲望。笔者在撰写此文的时候，正逢Firebug发布1.0正式版，这不能不说是种巧合。

				<span class="readmore"><a href="http://www.ooso.net/archives/294" title="初识Firebug 全文 &#8212; firebug的使用">阅读全文（3969字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>本文最初发表《程序员》杂志第三期，现将全文贴上，内容已经过编辑修饰了很多:)</p>
<h3>什么是Firebug</h3>
<p>从事了数年的Web开发工作，越来越觉得现在对WEB开发有了更高的要求。要写出漂亮的HTML代码；要编写精致的CSS样式表展示每个页面模块；要调试<a href="http://www.ooso.net/index.php/archives/category/javascript/">javascript</a>给页面增加一些更活泼的要素；要使用Ajax给用户带来更好的体验。一个优秀的WEB开发人员需要顾及更多层面，才能交出一份同样优秀的作业。为帮助广大正处于Web2.0洪流中的开发人员，在这里为大家介绍一款轻巧灵活的辅助开发工具。</p>
<p>Firebug是Firefox下的一款开发类插件，现属于<a href="http://www.ooso.net/index.php/archives/category/firefox/">Firefox</a>的五星级强力推荐插件之一。它集HTML查看和编辑、Javascript控制台、网络状况监视器于一体，是开发JavaScript、CSS、HTML和Ajax的得力助手。Firebug如同一把精巧的瑞士军刀，从各个不同的角度剖析Web页面内部的细节层面，给Web开发者带来很大的便利。这是一款让人爱不释手的插件，如果你以前没有接触过它，也许在阅读本文之后，会有一试的欲望。笔者在撰写此文的时候，正逢Firebug发布1.0正式版，这不能不说是种巧合。<br />
<span id="more-294"></span></p>
<h3>应用</h3>
<p>Firebug插件虽然功能强大，但是它已经和Firefox浏览器无缝地结合在一起，使用简单直观。如果你担心它会占用太多的系统资源，也可以方便地启用/关闭这个插件，甚至针对特定的站点开启这个插件。</p>
<p>在安装好插件之后，先用Firefox浏览器打开需要测试的页面，然后点击右下方的绿色按钮或使用快捷键F12唤出Firebug插件，它会将当前页面分成上下两个框架，如图1所示。</p>
<p>图1：Firebug插件展开图示<br />
<img src="http://www.ooso.net/wp-content/uploads/2007/firebug1.png" alt="firebug插件展开图示" /><br />
从图1中看到，Firebug有6个主要的Tab按钮，下文将主要介绍介绍这几方面的功能。</p>
<table border="1" cellpadding="4">
<tr>
<td>Console</td>
<td>	HTML</td>
<td>	CSS</td>
<td>	Script</td>
<td>	Dom</td>
<td>	Net</td>
</tr>
<tr>
<td>控制台</td>
<td>	Html查看器</td>
<td>	Css查看器</td>
<td>	脚本条时期	</td>
<td>Dom查看器</td>
<td>	网络状况监视</td>
</tr>
</table>
<h3>Console 控制台</h3>
<p>控制台能够显示当前页面中的javascript错误以及警告，并提示出错的文件和行号，方便调试，这些错误提示比起浏览器本身提供的错误提示更加详细且具有参考价值。而且在调试Ajax应用的时候也是特别有用，你能够在控制台里看到每一个XMLHttpRequests请求post出去的参数、URL，http头以及回馈的内容，原本似乎在幕后黑匣子里运作的程序被清清楚楚地展示在你面前。</p>
<p>象C shell或Python shell一样，你还能在控制台中查看变量内容，直接运行javascript语句，就算是大段的javascript程序也能够正确运行并拿到运行期的信息。</p>
<p>控制台还有个重要的作用就是查看脚本的log, 从前你也许习惯了使用alert来打印变量，但是Firebug给我们带来了一个新朋友 —— console.log, 最简单的打印日志的语法是这样的：  </p>
<div class="igBar"><span id="lcode-11"><a href="#" onclick="javascript:showCodeTxt('code-11'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-11">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">console.<span style="">log</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#CC0000;">"hello world"</span><span style="color:#006600; font-weight:bold;">&#41;</span> </div>
</li>
</ol>
</div>
</div>
</div>
<p>
如果你有一堆参数需要组合在一起输出，可以写成这样：</p>
<div class="igBar"><span id="lcode-12"><a href="#" onclick="javascript:showCodeTxt('code-12'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-12">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">console.<span style="">log</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#800000;color:#800000;">2</span>,<span style="color:#800000;color:#800000;">4</span>,<span style="color:#800000;color:#800000;">6</span>,<span style="color:#800000;color:#800000;">8</span>,<span style="color:#CC0000;">"foo"</span>,bar<span style="color:#006600; font-weight:bold;">&#41;</span>. </div>
</li>
</ol>
</div>
</div>
</div>
<p>
Firebug的日志输出有多种可选的格式以及语法，甚至可以定制彩色输出，比起单调的alert，显然更加方便，限于篇幅，这里不做详细说明，但是有志于提高debug效率的读者，可以到Firebug的官方站点（见附录）查看更详细的教程。</p>
<p>图2： 在控制台里调试javascript<br />
<img src="http://www.ooso.net/wp-content/uploads/2007/firebug2.png" alt="在控制台里调试javascript" /></p>
<h3>查看和修改HTML</h3>
<p>第一次看到Firebug强大的HTML代码查看器，就觉得它与众不同，相比于Firefox自带的HTML查看器，它的功能强大了许多。 HTML</p>
<p>首先你看到的是已经经过格式化的HTML代码，它有清晰的层次，你能够方便地分辨出每一个标签之间的从属并行关系，标签的折叠功能能够帮助你集中精力分析代码。源代码上方还标记出了DOM的层次，如图3所示，它清楚地列出了一个hml元素的parent、child以及root元素，配合Firebug自带的CSS查看器使用，会给div+css页面分析编写带来很大的好处。你还可以在HTML查看器中直接修改HTML源代码，并在浏览器中第一时间看到修改后的效果，光凭这一点就会让许多页面设计师死心塌地地成为Firebug的粉丝了。</p>
<p>有时候页面中的javascript会根据用户的动作如鼠标的onmouseover来动态改变一些HTML元素的样式表或背景色，HTML查看器会将页面上改变的内容也抓下来，并以黄色高亮标记，让网页的暗箱操作彻底成为历史。</p>
<p>利用Inspect检查功能，我们还可以用鼠标在页面中直接选择一些区块，查看相应的HTML源代码和CSS样式表，真正的做到所见即所得，如果你使用了外部编辑器修改了当前网页，可以点击Firebug的reload图片重新载入网页，它会继续跟踪你之前用Inspect选中的区块，方便调试。</p>
<p>图3:：HTML查看器<br />
<img src="http://www.ooso.net/wp-content/uploads/2007/firebug3.png" alt="HTML查看器" /></p>
<h3>CSS调试</h3>
<p>Firebug的CSS调试器是专为网页设计师们量身定做的。</p>
<p>如今的网页设计言必称div+css，如果你是用table套出来的HTML页面，就得按这规矩重构一遍，否则显得你不够时髦！用div做出来的页面的确能精简HTML代码，HTML标签减肥的结果就是CSS样式表的编写成了页面制作的重头戏。Firebug的CSS查看器不仅自下向上列出每一个CSS样式表的从属继承关系，还列出了每一个样式在哪个样式文件中定义。你可以在这个查看器中直接添加、修改、删除一些CSS样式表属性，并在当前页面中直接看到修改后的结果。</p>
<p>一个典型的应用就是页面中的一个区块位置显得有些不太恰当，它需要挪动几个象素。这时候用CSS调试工具可以轻易编辑它的位置——你可以根据需要随意挪动象素。<br />
如图4中正在修改一个区块的背景色。</p>
<p>提示：如果你正在学习CSS样式表的应用，但是总记不住常用的样式表有哪些值，可以尝试在CSS调试器中选中一个样式表属性，然后用上下方向键来改变它的值，它会把可能的值一个个遍历给你看。</p>
<p>图4: CSS查看器，能够直接修改样式表<br />
<img src="http://www.ooso.net/wp-content/uploads/2007/firebug4.png" alt="图4: CSS查看器，能够直接修改样式表" /></p>
<h3>可视化的CSS尺标</h3>
<p>我们可以利用Firebug来查看页面中某一区块的CSS样式表，如果进一步展开右侧Layout tab的话，它会以标尺的形式将当前区块占用的面积清楚地标识出来，精确到象素，更让人惊讶的是，你能够在这个可视化的界面中直接修改各象素的值，页面上区块的位置就会随改动而变化。在页面中某些元素出现错位或者面积超出预料值时，该功能能够提供有效的帮助，你可以籍此分析offset、margin、padding、size之间的关系，从而找出解决问题的办法。</p>
<p>图5：Firebug中的CSS标尺<br />
<img src="http://www.ooso.net/wp-content/uploads/2007/firebug5.png" alt="图5：Firebug中的CSS标尺" /></p>
<h3>网络状况监视器</h3>
<p>也许有一天，你的老板或者客户找到你，抱怨你制作的网页速度奇慢，你该如何应对？你或许会说这可能是网络问题，或者是电脑配置问题，或者是程序太慢，或者直说是他们的人品问题？不管怎么说，最后你可能被要求去解决这个有多种可能的问题。</p>
<p>网络状况监视器能帮你解决这个棘手问题。Firebug的网络监视器同样是功能强大的，它能将页面中的CSS、javascript以及网页中引用的图片载入所消耗的时间以矩状图呈现出来，也许在这里你能一把揪出拖慢了你的网页的元凶，进而对网页进行调优，最后老板满意客户欢喜，你的饭碗也因此而牢固。</p>
<p>网络监视器还有一些其它细节功能，比如预览图片，查看每一个外部文件甚至是xmlHttpRequests请求的http头等等。</p>
<p>图6：网络状况监视器<br />
<img src="http://www.ooso.net/wp-content/uploads/2007/firebug6.png" alt="图6：网络状况监视器" /></p>
<h3>Javascript调试器</h3>
<p>这是一个很不错的javascript脚本调试器，占用空间不大，但是单步调试、设置断点、变量查看窗口一个不少。正所谓麻雀虽小，五脏俱全。</p>
<p>如果你有一个网站已经建成，然而它的javascript有性能上的问题或者不是太完美，可以通过面板上的Profile来统计每段脚本运行的时间，查看到底是哪些语句执行时间过长，一步步排除问题。</p>
<p>图7：javascript调试器<br />
<img src="http://www.ooso.net/wp-content/uploads/2007/firebug7.png" alt="图7：javascript调试器" /></p>
<h3>DOM查看器</h3>
<p>DOM(Document Object Model)里头包含了大量的Object以及函数、事件，在从前，你要想从中查到需要的内容，绝非易事，这好比你去了一个巨大的图书馆，想要找到几本名字不太确切的小书，众多的选择会让你无所适从。而使用Firebug的DOM查看器却能方便地浏览DOM的内部结构，帮助你快速定位DOM对象。双击一个DOM对象，就能够编辑它的变量或值，编辑的同时，你可能会发现它还有自动完成功能，当你输入document.get之后，按下tab键就能补齐为document.getElementById，非常方便。如果你认为补齐得不够理想，按下shift+tab又会恢复原状。用了Firebug的DOM查看器，你的javascript从此找到了驱使的对象，Web开发也许就成了一件乐事。</p>
<p>图8: Dom查看器<br />
<img src="http://www.ooso.net/wp-content/uploads/2007/firebug8.png" alt="图8: Dom查看器" /></p>
<h3>小结</h3>
<p>Firebug插件提供了一整套web开发所必需的工具。从HTML的编写，到CSS样式表的美化调优，以及用javascript脚本开发，亦或是Ajax应用，Firebug插件都会成为你的得力助手。所谓工欲善其事，必先利其器。在Web2.0的时代，言必称Ajax，动辄就是用户体验提升，如果把Firebug工具用好，必能让你如虎添翼，将HTML、CSS、javascript整理得服服帖帖，从此成为web开发中的专家级人物。</p>
<h3>附</h3>
<p>Firebug的中文含义是萤火虫，作者是Joe Hewitt，官方网页 http://www.getfirebug.com<br />
Firefox亦即火狐浏览器，是近年来撼动IE浏览器市场占有率的一支强大力量，要不是它的出现，我想有生之年说不定也看不到IE 7的发布了，官方网页 http://www.firefox.com</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/294/feed</wfw:commentRss>
		<slash:comments>29</slash:comments>
		</item>
		<item>
		<title>初识firebug 发表了</title>
		<link>http://www.ooso.net/archives/288</link>
		<comments>http://www.ooso.net/archives/288#comments</comments>
		<pubDate>Tue, 24 Apr 2007 00:02:51 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[firebug]]></category>
		<category><![CDATA[插件]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/288</guid>
		<description><![CDATA[俺滴第一次投稿 ——《初识Firebug》在程序员第3期上发表了，样刊直到最近几天才看到。习惯在浏览器上阅读文字，看到纸质的杂志，却是另外一番感受。
Firebug是Firefox下的一款开发类插件，现属于Firefox的五星级强力推荐插件之一。它集HTML查看和编辑、Javascript控制台、网络状况监视器于一体，是开发JavaScript、CSS、HTML和Ajax的得力助手。Firebug如同一把精巧的瑞士军刀，从各个不同的角度剖析Web页面内部的细节层面，给Web开发者带来很大的便利。这是一款让人爱不释手的插件，如果你以前没有接触过它，也许在阅读本文之后，会有一试的欲望。

				<span class="readmore"><a href="http://www.ooso.net/archives/288" title="初识firebug 发表了">阅读全文（402字）</a></span>]]></description>
			<content:encoded><![CDATA[<p>俺滴第一次投稿 ——《初识Firebug》在程序员第3期上发表了，样刊直到最近几天才看到。习惯在浏览器上阅读文字，看到纸质的杂志，却是另外一番感受。</p>
<blockquote><p>Firebug是Firefox下的一款开发类插件，现属于Firefox的五星级强力推荐插件之一。它集HTML查看和编辑、Javascript控制台、网络状况监视器于一体，是开发JavaScript、CSS、HTML和Ajax的得力助手。Firebug如同一把精巧的瑞士军刀，从各个不同的角度剖析Web页面内部的细节层面，给Web开发者带来很大的便利。这是一款让人爱不释手的插件，如果你以前没有接触过它，也许在阅读本文之后，会有一试的欲望。</p></blockquote>
<p>在写这篇文章之前，我对firebug的理解程度也只是皮毛而已，实在是惭愧。做了些功课以后，越发能感觉到Firebug实在是不可多得的精品插件，的确能提高俺的工作效率，在此向所有web开发者推荐！</p>
<p>附:<br />
<a href="http://www.ooso.net/index.php/archives/294">初识firebug全文</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/288/feed</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Firebug 1.0 beta is out</title>
		<link>http://www.ooso.net/archives/268</link>
		<comments>http://www.ooso.net/archives/268#comments</comments>
		<pubDate>Wed, 06 Dec 2006 01:06:44 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[firebug]]></category>
		<category><![CDATA[插件]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/268</guid>
		<description><![CDATA[Firebug是firefox下的一个巨好的插件!----Web开发工程师一定会深深喜欢这个plugin的.

就目前来说,它有几个优点让俺无法割舍


				<span class="readmore"><a href="http://www.ooso.net/archives/268" title="Firebug 1.0 beta is out">阅读全文（249字）</a></span>]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.getfirebug.com">Firebug</a>是<a href="http://www.ooso.net/index.php/archives/category/firefox/">firefox</a>下的一个巨好的<a href="http://www.ooso.net/?tag=%E6%8F%92%E4%BB%B6">插件</a>!----Web开发工程师一定会深深喜欢这个plugin的.<br />
<img src="http://www.getfirebug.com/html1.gif" alt="firebug" width="100%" /></p>
<p>就目前来说,它有几个优点让俺无法割舍</p>
<ul>
<li>方便的查看页面的源代码,绝对比你"右键点击页面->查看源代码"要有效率</li>
<li>查看页面某一区块的样式表,比如说你可以看看某一块页面上的背景图在样式表中是如何定义的,web开发的老手一定会了解我说的这个操作在手工进行的时候是多么麻烦----当然,如果你早就用上了firebug我只能恭喜你</li>
<li>
调试javascript! Debug你的Ajax程序!</li>
</ul>
<p><strong>工欲善其事,必先利其器</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/268/feed</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>我使用的firefox插件</title>
		<link>http://www.ooso.net/archives/223</link>
		<comments>http://www.ooso.net/archives/223#comments</comments>
		<pubDate>Tue, 22 Aug 2006 23:50:11 +0000</pubDate>
		<dc:creator>Volcano</dc:creator>
				<category><![CDATA[firefox]]></category>
		<category><![CDATA[firebug]]></category>
		<category><![CDATA[yahoo]]></category>
		<category><![CDATA[插件]]></category>

		<guid isPermaLink="false">http://www.ooso.net/index.php/archives/223</guid>
		<description><![CDATA[FireGestures
鼠标手势，感觉像用鼠标来搓拳皇的招式。一鼠在手，江山我有。All-in-one Gestures的替代插件
Easy DragToGo
Super Drag And Drop的替代插件，不仅能够拖动链接，还能在网页上选取一些词直接拖到搜索框里。见Easy DragToGo — Super Drag and Drop的替代品

				<span class="readmore"><a href="http://www.ooso.net/archives/223" title="我使用的firefox插件">阅读全文（1109字）</a></span>]]></description>
			<content:encoded><![CDATA[<h3><a href="https://addons.mozilla.org/en-US/firefox/addon/6366">FireGestures</a></h3>
<p>鼠标手势，感觉像用鼠标来搓拳皇的招式。一鼠在手，江山我有。All-in-one Gestures的替代插件</p>
<h3><a href="https://addons.mozilla.org/en-US/firefox/addon/6639">Easy DragToGo</a></h3>
<p>Super Drag And Drop的替代插件，不仅能够拖动链接，还能在网页上选取一些词直接拖到搜索框里。见<a href="http://www.ooso.net/index.php/archives/426">Easy DragToGo — Super Drag and Drop的替代品</a></p>
<h3><a href="http://userstyles.org/stylish/">Stylish</a></h3>
<p>Stylish is a Firefox, Thunderbird, Flock, SeaMonkey, Mozilla Suite, and Songbird extension that allows easy management of user styles. User styles empower your browsing experience by letting you fix ugly sites, customize the look of your browser or mail client, or just have fun. With an online repository at userstyles.org, you don't even need to know how to write styles yourself; just a couple clicks and the chosen style is applied. Stylish is to CSS what Greasemonkey is to JavaScript, and unlike other methods of using user styles, most styles take effect immediately.</p>
<h3><a href="http://www.greasespot.net/">greasemonkey</a></h3>
<p>小猴子插件的最大好处是，可以针对某些网站自定义一些javascript脚本，有选择的显示网页上的内容或是改变显示效果。</p>
<h3><a href="http://foxyproxy.mozdev.org/">Foxyproxy</a></h3>
<p>偶尔要使用代理翻墙出去看网页的时候，用Foxyproxy轻松切换，很爽。</p>
<h3><a href="http://adblockplus.org/">Adblock plus</a></h3>
<p>和网页上的垃圾广告说bye bye~~</p>
<h3><a href="http://www.ooso.net/index.php/archives/294">firebug</a></h3>
<p>web开发者必备的一个插件！！，见本人写的<a href="http://www.ooso.net/index.php/archives/294">初识Firebug 全文 — firebug的使用</a></p>
<h3><a href="https://addons.mozilla.org/en-US/firefox/addon/3255">CookieSwap</a></h3>
<p><a href="http://www.ooso.net/index.php/archives/341">Cookie切换插件</a>，轻松改变在bbs上的登录身份，成为马甲之王。</p>
<h3><a href="https://addons.mozilla.org/firefox/1419/">IE Tab</a></h3>
<p>可以在firefox里切换回IE来浏览当前网页。见<a href="http://www.ooso.net/index.php/archives/246">firefox插件–IE Tab</a></p>
<h3><a href="http://livehttpheaders.mozdev.org">Live Http headers</a></h3>
<p>做web开发的话，这个插件可以说帮助很大，能看到所访问页面的头信息如cookie,http 302或是200 ok，更可以模拟表单POST，感觉真的是很有用。</p>
<h3><a href="http://developer.yahoo.com/yslow">YSlow</a></h3>
<p>经验老到的web开发者应该熟练使用本工具，这样可以查看你的网页为什么会显示缓慢。</p>
<p>每个人都有不同的喜好，因此插件的搭配也会各个不同。记录下来，是为了以后可以回溯</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ooso.net/archives/223/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
