A Content Publishing Example
Let’s look at an example of how a content publishing system might work. This example illustrates how an online publication like a magazine or newspaper might publish articles using a template system. In this case, the page will be generated every time the user visits the page. The system consists of three components: a story-input program (which allows writers to submit stories), the stories themselves, and a story-display program (which applies a template to a story and displays it in the browser).
First let’s look at the template file and the data files. The template looks like a regular HTML file but it contains placeholders that take will be populated with content from the data files. The template file is included ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access