Using Firebug to identify Wordpress files

310 views
Skip to first unread message

Eric Reynolds

unread,
Aug 17, 2010, 8:57:20 PM8/17/10
to Firebug
I've been using Firebug to proof changes for html pages, and it's been
great. Now, I am proofing a Wordpress site, and dealing with php and
CSS files. No problem with identifying the CSS. Yet I don't know how
to identify where changes need to be made in viewing php files. I make
corrections in Firebug, but I have to go headhunting for the code
because Firebug doesn't tell me the page that I am viewing. Any help
appreciated.

Mike Ratcliffe

unread,
Aug 18, 2010, 3:00:03 AM8/18/10
to Firebug
In the HTML tab select "Show Comments" from the tabs dropdown ... the
wordpress templates files include comments that identify them.

On Aug 18, 2:57 am, Eric Reynolds <trancefusiondes...@gmail.com>
wrote:

Eric Reynolds

unread,
Aug 18, 2010, 3:44:20 AM8/18/10
to Firebug
Thanks Mike. Of course, by default, a Firebug user would assume that
the coding comes from the page that's being viewed. But, with
Wordpress, the php is mixed in with html.

Unfortunately, the comments, in green, don't identify the page where
the code resides. The comments only display basic info about the
actual code. I was wondering if Firebug could indicate something like
"source code from header.php" or something like that so I would know
that I have to finalize my code revisions or additions in that file.

I hope this makes sense.

Eric

On Aug 18, 12:00 am, Mike Ratcliffe <mich...@ratcliffefamily.org>
wrote:

Mike Ratcliffe

unread,
Aug 18, 2010, 6:06:19 AM8/18/10
to Firebug
The browser has no knowledge of which templates have been used to
create a file. The only thing that you can do is add comments to the
php templates.

e.g.
Before the first HTML tag in header.php:
<!-- header.php: START -->

After the last HTML tag:
<!-- header.php: END -->

On Aug 18, 9:44 am, Eric Reynolds <trancefusiondes...@gmail.com>

Eric Reynolds

unread,
Aug 18, 2010, 11:32:18 AM8/18/10
to Firebug
Thank you for the clarification. I guess this is why it's important to
leave comments. :)

On Aug 18, 3:06 am, Mike Ratcliffe <mich...@ratcliffefamily.org>

Mike Bird

unread,
Aug 31, 2013, 1:04:59 PM8/31/13
to fir...@googlegroups.com

After much research I don't believe it can be done in Firebug - directly. What worked for me was to inspect an element, note something unique about it (or nearby), then use FileSeek to search the theme you are using. If you installed the theme direct from the web, just download a copy to your computer and use FileSeek to search it (the program will quickly search for text within files - and is free).

Hope this helps.

Reply all
Reply to author
Forward
0 new messages