Re: Has anybody used a SQL database to store static pages without using PHP?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I was going to reply the same: you can, but you probably shouldn't.

Databases aren't built for speed. They are built for robustness: Atomicity, Consistency, Isolation, and Durability (ACID). If that's what you need, then you should use a database. Otherwise just use the filesystem. It's designed to be able to return you your data as fast as possible. If you need even more speed, then distribute your data to a Content Delivery Network (CDN) so it's closer to your users. (I think the previous answerer meant to use the term CMS (Content Management System) where they used CDN).

/Colin

On Wed, 4 Sep 2019 at 09:12, @lbutlr <kremels@xxxxxxxxx> wrote:
On 1 Sep 2019, at 01:39, timothylegg . <timothydlegg@xxxxxxxxx> wrote:
> Can you store an entire static page in an SQL database such as MariaDB
> or MySQL and have httpd initiate the database query by parsing the
> search parameter from the URL?  i.e.
> https://www.example.org/benny/index.html would search a table for
> "/benny/index.html" and return back a corresponding VARCHAR, or maybe
> BLOB, that contains the entire HTML document.

Sure.

> Searching for this idea on a modern search engine was maddening.


Just because you can do it, doesn’t mean it’s a good idea. The way to do this is to use a CDN that load the contents for pages dynamically into a template document.

WordPress, for example. There are, of course, many other choices.


--
The King of Marigold was in the kitchen cooking breakfast for the Queen
The Queen was in the parlor playing piano for the children of the King


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux