• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Firebug question

 
Arjun Reddy
Ranch Hand
Posts: 629
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I inspected a page's code but when I do view source on that page, I do not see the code I saw when I inspected (Using the inspect button of firebug) using firebug. Am I doing something wrong?

Thanks.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65120
91
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
View source will show you the response. Firebug inspection will show you that actual DOM.
 
Arjun Reddy
Ranch Hand
Posts: 629
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ok say I want to put a div tag around the div tag I am currently inspecting right now. What should I be doing then? Where should I do the changes as I cannot see these in the view page source.

Thanks.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65120
91
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I repeat: View Source shows the source; that is, the original HTML as it was sent as the response. Period. Anything you do to the page after that is not reflected in this. It is will always and forever show the response.
 
Arjun Reddy
Ranch Hand
Posts: 629
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Bear Bibeault wrote:I repeat: View Source shows the source; that is, the original HTML as it was sent as the response. Period. Anything you do to the page after that is not reflected in this. It is will always and forever show the response.


I am not talking about the changes showing up in the html page's view source. I am talking about how to make changes to the inspecting div tag I am looking at right now using firebug.

Thanks.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65120
91
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No getting you.
 
Arjun Reddy
Ranch Hand
Posts: 629
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ok. I am looking at two tables in separate div tags say div1 and div2 and I want to put a new div tag say div3 around div1 and div2. I can see div1 and div2 using the firebug inspect option but cannot see them when I do view page source. So right now, I don't know where to put the div3. Sorry for the confusion.

Thanks.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65120
91
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you mean under JavaScript control? What does all this have to do with Firebug and View Source?
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As Bear has said many times, the View Source that you get from Ctrl-U or the View Menu is the data from the server that was originally brought down. The changes to the DOM are in memory, they are not in a physical file so viewing the page source open helps when you are looking at what was returned from the server, not when you want to see what JavaScript did to the page.

Eric
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic