It was a few days ago that I was thinking about search engines crawling through this website.
I began to wonder just how many web pages there are here. To calculate this total, it's not
just a simple matter of counting files on disk. Most of the web pages are created from entries
in the database. One recent evening, I started to design a formula to find out how many web pages
there are. Roughly. This will not be 100% accurate, but it will be close.
Pages on disk
First, let's count the number of pages on disk:
$ ls *.php | wc -l
69
Number of categories
There is a page for each category:
# select count(*) from categories;
count
-------
120 (1 row)
Number of ports
There are ports, and there are deleted ports. I'll show both:
# select count(*) from ports_all where status = 'A';
count
-------
33971
# select count(*) from ports_all where status = 'D';
count
-------
24854 (1 row)