title: Best way to manage dynamic content without databases
body: <p>I am designing a web application which will be doing three things:</p>
  
  <p>1) store some data</p>
  
  <p>2) make user available to view these data</p>
  
  <p>3) from time to time add/remove/change some data</p>
  
  <p>Looks pretty simple, but I would like to minimase usage of server resources by avoiding MySQL and PHP. My main goal is to deliver HTML file for user - posts1.html (posts2.html, posts3.html... (where 1,2,3 are numbers of pages of data)).</p>
  
  <p>Normally, I would create posts.php file, which would send query to database, but my data are changing only three-five times a day, so it would be a huge waste.</p>
  
  <p>Instead, I thought about caching these data, what would spare a lot of server resources, but in this situation there would be some of PHP code involved.</p>
  
  <p>My another idea is to create script that would be creating all HTML files after every change in database and then replace the old ones with them. But what if someone requests page that is replacing right now? It may cause errors, user can get the uncompleted file etc.</p>
  
  <p>However, there is one solution - I could store created HTML files in two directories (A and B) and using .htaccess do something like this (pseudocode):</p>
  
  <pre><code>if ( (HOURS)%2 == 0 )
     /postsX.html -&gt; /A/postsX.html
  else
     /postsX.html -&gt; /B/postsX.html
  </code></pre>
  
  <p>It would give me enough time to upgrade all files.</p>
  
  <p>I would love to hear what do you think about it and what would you do?</p>