What are these routing styles called in a web application?

190 views Asked by At

What do you call routing that maps one URL directly to a file?

Example:

http://localhost/directory/file.php => /var/www/apache/htdocs/directory/file.php

What do you call routing like one on https://github.com/nikic/FastRoute?

Example:

http://localhost/directory/file => request actually goes to a single index.php file, which then loads routing files or tables and loads appropriate class as defined in the routing table.

1

There are 1 answers

2
Alex Howansky On BEST ANSWER

What do you call routing that maps one URL directly to a file?

I would call that no routing. Or maybe direct routing? I've never heard anybody use a term specifically for it.

What do you call routing like one on https://github.com/nikic/FastRoute?

That's (typically) the front controller pattern.