Closed
Bug 302617
Opened 19 years ago
Closed 17 years ago
view source is not same that the served page
Categories
(Toolkit :: View Source, defect)
Tracking
()
RESOLVED
WORKSFORME
People
(Reporter: mail, Unassigned)
References
()
Details
(Whiteboard: DUPEME?)
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8b3) Gecko/20050712 Firefox/1.0+ Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8b3) Gecko/20050712 Firefox/1.0+ By server side scripting, page is served as application/xhtml+xml for browser that support it, and as text/html for browser that don't support it. View source represent the code served as text/html instead of the one served as application/xhtml+xml Reproducible: Always Steps to Reproduce: 1. Open url www.fruibile.it 2. Right click on page and click on "View Page Source" (show the code as served as text/html). 3. Right click on page and click "View page info" (shows that is correctly served as application/xhtml). 4. Try to save the page with "File - Save page As" (save the page in a mixed version of application/xhtml+xml and text/html Actual Results: Show wrong code Expected Results: Show right code as parsed by browser
Comment 1•19 years ago
|
||
Possibly a dupe of bug 225979?
Reporter | ||
Comment 2•19 years ago
|
||
It persist also with Deer Park Alpha 2.
Comment 3•19 years ago
|
||
I can see this in a frame that is server generated. I reload the frame but it is still the old source. The frame shows the correct content in the browsing window. using Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20050821 Firefox/1.6a1
Reporter | ||
Comment 4•19 years ago
|
||
Yes, u need to reload the page before Mozilla update the right content. If u use another browser that support application/xhtml like Opera this problem don't is available.
Comment 5•19 years ago
|
||
This bug occurs with the latest netscape, whether you use IE or Firefox as the rendering engine. It also occurs with firefox itself in the 1.0.7 I'm using, and the dearpark. I know that they are all basically "fixing" the code I guess before they are being rendered, and what the "view source" is doing is outputting the "fixed" code, and not the original. This is bad, because you don't know if you've made errors, and a lot of people like me use firefox for development, and if we're using a scripting language we need to see the RAW output, not the fixed stuff. Therefore a good way to fix this, may be to under the "View" menu to put, "view as original" or something like that. This preference either should be automatically saved, or/and be in the options as a permanent preference. For now, I'm not using firefox or netscape for development anymore, because it can lead to problems. (In reply to comment #0) > User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8b3) Gecko/20050712 Firefox/1.0+ > Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8b3) Gecko/20050712 Firefox/1.0+ > > By server side scripting, page is served as application/xhtml+xml for browser > that support it, and as text/html for browser that don't support it. > View source represent the code served as text/html instead of the one served as > application/xhtml+xml > > Reproducible: Always > > Steps to Reproduce: > 1. Open url www.fruibile.it > 2. Right click on page and click on "View Page Source" (show the code as served > as text/html). > 3. Right click on page and click "View page info" (shows that is correctly > served as application/xhtml). > 4. Try to save the page with "File - Save page As" (save the page in a mixed > version of application/xhtml+xml and text/html > > Actual Results: > Show wrong code > > Expected Results: > Show right code as parsed by browser
Comment 6•19 years ago
|
||
For example go to: http://www.sunraystudios.com/misc/bug.html The ACTUAL source=> <html> <script>unclosed </html> the VIEW SOURCE=> <html> <script></script>unclosed </html> the File=>Save Page As results=> <html> <script>unclosed </html> Therefore the issue is that it is trying to output the DOM-compliant stuff, instead of the actual source.
I'd say severity MAJOR as viewing source is so important. The first idea of viewing the original source as 'view original' is wrong - there should be one view source which shows always the original source. A button could be placed on the view source pane to format, and another to 'tidy' the html tags around, using the identical code that firefox now uses to fix the code in the current broken view source. If someone wants html tidy to be implemented, this shoudl yet again be another option, but don't hide the current firefox code fixing, because that is also important (to show how firefox fixes and interprets given code)
I also have this issue. For me, I'm trying to view the source code of a restricted "login-required" page: /members-only/ ...but the source code is displaying the login page where the browser is directed to if there is no logged-in session: /login.php I cannot find a way of viewing the source of a restrited page! Using FF 1.5. Quinn
Comment 9•18 years ago
|
||
It's severity is MAJOR ... when I select "view source", I want to see SOURCE, not FireFox's interpretation of what the source should have been. Changing the menu item to say: "View Corrected Source", or adding a warning that FF has possibly changed the source, would be the fast fix, but not being able to see the original source makes FF useless as for debugging simple HTML. This has already caused me a lot of problems: we were blaming translation software for corrupting HTML when the problem was a stray quote inside an IMG tag in the English source. There was no visible problem in the source, when viewed in FF. Later, someone looked at the source with MSIE and found the error.
Comment 10•18 years ago
|
||
It's severity is MAJOR ... when I select "view source", I want to see SOURCE, not FireFox's interpretation of what the source should have been. Changing the menu item to say: "View Corrected Source", or adding a warning that FF has possibly changed the source, would be the fast fix, but not being able to see the original source makes FF useless as for debugging simple HTML. This has already caused me a lot of problems: we were blaming translation software for corrupting HTML when the problem was a stray quote inside an IMG tag in the English source. There was no visible problem in the source, when viewed in FF. Later, someone looked at the source with MSIE and found the error.
Comment 11•18 years ago
|
||
There should be 3 View / Save Page options: (please also see link to CSS saving bugs). Save / View source - Save / View the files that were sent from the server Save / View FireFox render source - Save / View a source render of FireFox's original DOM build of this source Save / View Page Snapshot - Save / View a source render of FireFox's CURRENT DOM snapshot, including anything that may have been altered by client side scripting, written into the page using doc.write and ajax type stuff. The first should be what is shown. IE shows original source, but KILLS you by saving it's own version of the source. Also, view source should NEVER EVER make a second request: - This is a security risk (you are sending a http request which is information from the computer) - This could cause problems with the current page (view source on a credit card payment page). This is CRITICAL, BLOCKING and CONFIRMED (even though I broke etiquette by talking about a few inter-related points here). Please update accordingly.
Comment 12•18 years ago
|
||
I haven't had this issue anymore. If you go to the page: http://www.sunraystudios.com/misc/bug.html It gives you the original source, not the fixed source. So has been fixed in 1.5 for quite some time by now, at least from what I can see. As far as seeing the current DOM snapshot, this would be nice if it were built-in, because I use "view as rendered source" extension for Firefox when doing AJAX/DHTML stuff, but it would be more convenient if it were just a built-in feature of the view source.
Comment 13•17 years ago
|
||
I'm still having this issue with a page I wrote that has a php function preventing non-logged in users from viewing the page. Even though I am logged in, the View Source shows the code of the redirected login page. I am assuming Camino is not serving up the cookies the page needs.
Updated•17 years ago
|
Whiteboard: DUPEME?
Comment 14•17 years ago
|
||
Can you attach a test case of the page you are having the problem with or point us to a URL? I'm not seeing this in the current trunk builds or in the 2.0.0.4 release.
Comment 15•17 years ago
|
||
Well, I had posted an example at: http://www.sunraystudios.com/misc/bug.html , but as I had noted, in Comment#12, the issue has been fixed for over a year. I checked again in the most recent version just now, and the source is the same as what is the actual source, so the fix still holds.
Comment 16•17 years ago
|
||
Yeah, I looked at the page and it looked good but it wasn't entirely self-explanatory. I'll resolve this as fixed. Thanks!
Status: UNCONFIRMED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Comment 17•17 years ago
|
||
It wasn't supposed to be self-explanatory, that's why I had commented here. This should have been set to resolved a year ago, as I noted, a year ago :>)
Comment 18•17 years ago
|
||
FIXED is reserved for bugs that were fixed by a specific, identifiable patch. Since we're not sure what code change fixed this, it should be resolved as WORKSFORME. ->WORKSFORME
Resolution: FIXED → WORKSFORME
Assignee | ||
Updated•16 years ago
|
Product: Firefox → Toolkit
You need to log in
before you can comment on or make changes to this bug.
Description
•