I wish to create a type of links web directory.
I must provide to customers the press count for every link clicked on.
To do this, I intend to play one of the 2 solutions :
- Whenever a user click a hyperlink, it's not the ultimate URL : it call a script (php, python etc...) that batches a counter right into a database, after which redirect towards the final URL : it appears in my experience quite slow. OR
- Whenever a user click a hyperlink, it call an easy apache URL which redirect towards the final URL (mod_rewrite or something like that) : no counter is up-to-date at the same time, only throughout the evening whenever a cron job will parse the apache log file. By by doing this, the consumer experience is faster and calculation postponed to some time with less overload.
Are you aware how you can implement solution 2) in apache configuration : that's :
If apache server at mydomain.tld get the URL :
It redirects to (http 301):