2 ms·
Ask HN: Sunday HTML Puzzler
I have a small website. It's just a lark. I probably make five bucks a year on it. So this isn't a critical question, just more of a puzzler.
Here's the site.
http://project-management-methodologies.net/
The thing is, just after I posted a link to it here on HN (when else?) suddenly the text in the HTML is not showing up.
Viewing the page source, the material is in there. I loaded in Firebug but it says it's not in there! Yet I can see it in page source. The HTML is not corrupted, all the tags close.
Best I can figure it's the Google AdSense code somehow corrupting the rest of the html.
Anybody care to take a look and share your thoughts?
Not important, like I said, but interesting, especially if it involves Google.
UPDATE: Now it's working again. @#$#@$!
Very interesting bug. I hope it repeats itself so I can track it down. I'm almost certain it was Google though.
You guys are awesome! All I do is ask the question on HN and five minutes later the site is working! :)
- deleted 17y ago[deleted]
- chasingsparks 17y agoWhen I commented that it was not working on the other thread, I had used Live HTTP Headers to see that it was responding with "Content-length: 0". The following seems to replicate everything you described. require 'gserver' class PuzzlerServer < GServer def initialize(port=10001, *args) super(port, *args) end def serve(io) data = io.readpartial(4096) io.puts "HTTP1/x 200 OK" io.puts "Content-Length: #{(data =~ /good/i) ? data.length : 0}" io.puts "Content-Type: text/html" io.puts io.puts(data) end end server = PuzzlerServer.new server.start server.join
- chasingsparks 17y agoInterestingly, the view source behavior is intermittent for me in Firefox on OSX. I had merely assumed Content-length: 0 would stop recv()ing. However, sometimes the page will render nothing for /bad while still having the source; other times it will render nothing with no source. Combination of load orders for /good and /bad seems non-deterministic. Firefox issue, maybe?