You would set the value affid=1234 from the URL as a session variable, so that it persists while the user browses around the site.
You can find this solution with a little searching, there are quite a few people discussion it on stackoverflow for example, but if you don’t know what to look for it can be hidden in plain sight.
Warning: You will have to edit your php, and understand more than just using plugins.
Hope it helps:
—-
<?php
$lead = $_GET[‘lead’]; $_SESSION[‘lead’] = $lead;
$url = parse_url(get_bloginfo(‘url’));
setcookie(“lead”, $lead, 0, $url[‘path’], $url[‘host’]); (set)
?>
To test:
<?php
echo ($_COOKIE[‘lead’]); // Lead Cookie
?>