Hacker News new | ask | show | jobs
by crazygringo 413 days ago
I think this is the most likely answer.

I'm not defending it, because when I started web development this was one of the first problems I ran into as well -- how the heck do you include a common header.

But the original concept of HTML was standalone documents, not websites with reusable components like headers and footers and navbars.

That being said, I still don't understand why then the frames monstrosity was invented, rather than a basic include. To save on bandwidth or something?

3 comments

Frames were widely abused by early web apps to do dynamic interfaces before XHR was invented/widely supported. The "app" had a bunch of sub-frames with all the links and forms carefully pointing to different frames in the frameset.

A link in a sidebar frame would open a link in the "editor" frame which loaded a page with a normal HTML form. Submitting the form reloaded it in that same frame. Often the form would have multiple submit buttons, one to save edits in progress and another to submit the completed form and move to the next step. The current app state was maintained server side and validation was often handled there save for some basic formatting client side JavaScript could handle.

This setup allowed even the most primitive frame-supporting browsers to use CRUD web apps. IIRC early web frameworks like WebObjects leaned into that model of web app.

Oh my goodness, yes you're right, I'd forgotten entirely about those.

They were horrible -- you'd hit the back button and only one of the frames would go back and then the app would be in an inconsistent state... it was a mess!

You needed to hit the reset button (and hoped it worked) and never the back button! Yes, I suffered through early SAP web apps built entirely with frames and HTML forms. It was terrible.

I don't love JavaScript monstrosities but XHR and dynamic HTML were a vast improvement over HTML forms and frame/iframe abuse.

Really well written web form applications were a delight in 2001 and a large improvement over conventional applications written in Windows. It helped that application data was in a SQL database, with a schema, protected by transactions, etc as opposed to a tangle of pointers that would eventually go bad and crash the app -- I made very complicated forms for demographic profiling, scientific paper submission, application submission, document search, etc. If you did not use "session" variables for application state this could at worst cause a desynchronization between the browser and the server which (1) would get resynchronized at any load or reload and (2) never get the system into a "stuck" state from the user viewpoint and (3) never lose more than a screen full of work.

Try some other architecture though and all bets were off.

Amazon's web store looked and worked mostly the same as it does now, people were very impressed with MapQuest, etc.

Applications like that can feel really fast, almost desktop application fast, if you are running them on a powerful desktop computer and viewing them on another computer or tablet over a LAN

To be fair, modern SAP web apps are also terrible.
The original concept of HTML was as an SGML subset, and SGML had this functionality, precisely because it's very handy for document authoring to be able to share common snippets.
A lot of early HTML was about taking the output of a different system such as a mainframe and putting that output into HTML.

Lots of gateways between systems.