<?php
// The URL you want to send people to after logging the backlink
$destination_url = 'https://www.yourwebsite.com/final-destination';
// Log the referrer (the site that sent the traffic)
$referrer = $_SERVER['HTTP_REFERER'] ?? 'Direct'; // Use 'Direct' if no referrer is set
// Here you can add code to store the $referrer in a database or log file for analysis later
// Now redirect the visitor to the final destination
header('Location: ' . $destination_url);
exit();
?>
// The URL you want to send people to after logging the backlink
$destination_url = 'https://www.yourwebsite.com/final-destination';
// Log the referrer (the site that sent the traffic)
$referrer = $_SERVER['HTTP_REFERER'] ?? 'Direct'; // Use 'Direct' if no referrer is set
// Here you can add code to store the $referrer in a database or log file for analysis later
// Now redirect the visitor to the final destination
header('Location: ' . $destination_url);
exit();
?>