Closed Bug 88226 Opened 24 years ago Closed 24 years ago

View source loosing dynamic content

Categories

(SeaMonkey :: General, defect)

x86
All
defect
Not set
normal

Tracking

(Not tracked)

VERIFIED DUPLICATE of bug 64100

People

(Reporter: djoham, Assigned: asa)

References

()

Details

From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.1+) Gecko/20010625 BuildID: 2001062508 OK, call me crazy but this bug is really weird. The short of it is, when you do a view source on a page that has dynamically generated content, the dynamically generated content is removed from the view source, even though it was displayed to the user. Weird? Dern straight... Go to http://12.150.65.16:8080/examples/jsp/mozilla/startform.html This is a page that simply submits the value that you typed into the text field to another (jsp) form. The JSP takes the inputted data and simply sends it back to the user. Here's the whole code to the JSP <html> <body> <form> the value that was posted is ---<%=request.getParameter("testText")%>--- </form> </body> </html> You'll notice that when the page renders to the user, all is well. But then do a view source. The area where the dynamic content was displayed is rendered in the view source as "null" Weird. Reproducible: Always Steps to Reproduce: 1.go to http://12.150.65.16:8080/examples/jsp/mozilla/startform.html 2.input data into the text field and submit 3.Notice that your data is echoed back to you in the return form 4.Do a view source, your data is missing Actual Results: The data is missing in a view source Expected Results: I expect to have the information sent to the browser displayed in view source exactly as sent. I've tried this on two different web servers, IIS and Tomcat. The only difference is that with Tomcat the dynamic content is replaced by a "null" wheras in IIS there is nothing there. My Tomcat server was a linux box where IIS was Win2K This reproduces on Linux and Windows clients. I haven't tried a mac. Mozilla does *not* do any server traffic during the view source so it's pulling from the cache. IE/NN4/Konq work as I would expect. There is virtually no difference in what is sent to the browser for Mozilla and Konqi. The only difference that I can see is the user agent string. Here's a network sniff of Moz and Konqi going through the recreation... mozilla load main page #### T 172.17.4.106:3009 -> 12.150.65.16:8080 [AP] GET /examples/jsp/mozilla/startform.html HTTP/1.1..Host: 12.150.65.16: 8080..User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.1+) G ecko/20010625..Accept: text/xml, application/xml, application/xhtml+xm l, text/html;q=0.9, image/png, image/jpeg, image/gif;q=0.2, text/plain ;q=0.8, text/css, */*;q=0.1..Accept-Language: en-us..Accept-Encoding: gzip,deflate,compress,identity..Accept-Charset: ISO-8859-1, utf-8;q=0. 66, *;q=0.66..Keep-Alive: 300..Connection: keep-alive..Cookie: JSESSIO NID=wc5r0vp2f1..If-Modified-Since: Thu, 28 Jun 2001 00:11:02 GMT..Cach e-Control: max-age=0.... ## T 12.150.65.16:8080 -> 172.17.4.106:3009 [AP] HTTP/1.0 200 OK..Content-Type: text/html..Content-Length: 165..Last-Mo dified: Thu, 28 Jun 2001 00:11:02 GMT..Servlet-Engine: Tomcat Web Serv er/3.2.2 (JSP 1.1; Servlet 2.2; Java 1.3.1; Linux 2.4.2-2 i386; java.v endor=Sun Microsystems Inc.)....<html>.<body>.<form action="postit.jsp " method="post">.<input type="text" name="testText" id="testText"><inp ut type="submit" value="submit">.</form>.</body>.</html>. ##### submit form #### T 172.17.4.106:3010 -> 12.150.65.16:8080 [AP] POST /examples/jsp/mozilla/postit.jsp HTTP/1.1..Host: 12.150.65.16:808 0..User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.1+) Geck o/20010625..Accept: text/xml, application/xml, application/xhtml+xml, text/html;q=0.9, image/png, image/jpeg, image/gif;q=0.2, text/plain;q= 0.8, text/css, */*;q=0.1..Accept-Language: en-us..Accept-Encoding: gzi p,deflate,compress,identity..Accept-Charset: ISO-8859-1, utf-8;q=0.66, *;q=0.66..Keep-Alive: 300..Connection: keep-alive..Cookie: JSESSIONID =wc5r0vp2f1..Referer: http://12.150.65.16:8080/examples/jsp/mozilla/st artform.html.. ## T 172.17.4.106:3010 -> 12.150.65.16:8080 [AP] Content-type: application/x-www-form-urlencoded..Content-Length: 12... .testText=foo.. ## T 12.150.65.16:8080 -> 172.17.4.106:3010 [AP] HTTP/1.0 200 OK..Content-Type: text/html;charset=ISO-8859-1..Servlet-E ngine: Tomcat Web Server/3.2.2 (JSP 1.1; Servlet 2.2; Java 1.3.1; Linu x 2.4.2-2 i386; java.vendor=Sun Microsystems Inc.)....<html>..<body>.. <form>..the value that was posted is ---foo---..</form>..</body>..</ht ml>.. ##### view source end view source konqi load main form #### T 172.17.4.106:3011 -> 12.150.65.16:8080 [AP] GET /examples/jsp/mozilla/startform.html HTTP/1.1..Connection: Keep-Al ive..User-Agent: Mozilla/5.0 (compatible; Konqueror/2.1.1; X11)..If-Mo dified-Since: Thu, 28 Jun 2001 00:11:02 GMT..Accept: text/*;q=1.0, ima ge/png;q=1.0, image/jpeg;q=1.0, image/gif;q=1.0, image/*;q=0.8, */*;q= 0.5..Accept-Encoding: x-gzip; q=1.0, gzip; q=1.0, identity..Accept-Cha rset: iso-8859-1;q=1.0, *;q=0.9, utf-8;q=0.8..Accept-Language: en_US, en..Host: 12.150.65.16:8080..Cookie: JSESSIONID=4wwdlep5i1.... ## T 12.150.65.16:8080 -> 172.17.4.106:3011 [AP] HTTP/1.0 200 OK..Content-Type: text/html..Content-Length: 165..Last-Mo dified: Thu, 28 Jun 2001 00:11:02 GMT..Servlet-Engine: Tomcat Web Serv er/3.2.2 (JSP 1.1; Servlet 2.2; Java 1.3.1; Linux 2.4.2-2 i386; java.v endor=Sun Microsystems Inc.)....<html>.<body>.<form action="postit.jsp " method="post">.<input type="text" name="testText" id="testText"><inp ut type="submit" value="submit">.</form>.</body>.</html>. ##### submit form #### T 172.17.4.106:3012 -> 12.150.65.16:8080 [AP] POST /examples/jsp/mozilla/postit.jsp HTTP/1.1..Connection: Keep-Alive ..User-Agent: Mozilla/5.0 (compatible; Konqueror/2.1.1; X11)..Referer: http://12.150.65.16:8080/examples/jsp/mozilla/startform.html..Pragma: no-cache..Cache-control: no-cache..Accept: text/*;q=1.0, image/png;q= 1.0, image/jpeg;q=1.0, image/gif;q=1.0, image/*;q=0.8, */*;q=0.5..Acce pt-Encoding: x-gzip; q=1.0, gzip; q=1.0, identity..Accept-Charset: iso -8859-1;q=1.0, *;q=0.9, utf-8;q=0.8..Accept-Language: en_US, en..Host: 12.150.65.16:8080..Cookie: JSESSIONID=4wwdlep5i1..Content-Type: appli cation/x-www-form-urlencoded.. ## T 172.17.4.106:3012 -> 12.150.65.16:8080 [AP] Content-Length: 12....testText=foo ## T 12.150.65.16:8080 -> 172.17.4.106:3012 [AP] HTTP/1.0 200 OK..Content-Type: text/html;charset=ISO-8859-1..Servlet-E ngine: Tomcat Web Server/3.2.2 (JSP 1.1; Servlet 2.2; Java 1.3.1; Linu x 2.4.2-2 i386; java.vendor=Sun Microsystems Inc.)....<html>..<body>.. <form>..the value that was posted is ---foo---..</form>..</body>..</ht ml>.. #### view source end view source go figure... Thanks for checking this out. I cannot figure for the life of me how this would be happening. How would Mozilla know what content is dynamic?
I think the problem may be that view source currently pulls the source off the server again rather than using the currently loaded version of the page. If that's the case then this is a dupe of bug 55583.
As reporter said, no server traffic. However, we still don't repost form data.... so we get the wrong thing from cache. Dupping to "view-source doesn't work for pages generated via forms with method=POST" *** This bug has been marked as a duplicate of 64100 ***
Status: UNCONFIRMED → RESOLVED
Closed: 24 years ago
Resolution: --- → DUPLICATE
v
Status: RESOLVED → VERIFIED
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.