How can the page know I'm analyzing it with fi

2020-03-12 06:53发布

Look:

Screenshot of Google identifying Firebug use!

Wow!

How can the webpage know I'm using firebug?

BTW I couldn't find out how to show the translucent add banner.

3条回答
Melony?
2楼-- · 2020-03-12 07:00

You can do:

if(window.console && window.console.firebug)
{
    alert("Firebug active!");
}
查看更多
▲ chillily
3楼-- · 2020-03-12 07:03

This works not only from the Firebug console, but also from within the page:

if (document.getElementById('_firebugConsole'))
   alert("fire!");
查看更多
闹够了就滚
4楼-- · 2020-03-12 07:15

Both answers will alert if the Firebug user has activated the Console panel. If users disable the Console panel, but leave the rest of Firebug up, the alerts will not fire (because Firebug does not inject the console object in that case).

查看更多
登录 后发表回答