You are working on a website with a referral program. When users refer others, you want to track the source of the referral using hidden form fields. Modify the HTML code below to achieve the same scenario.
Hidden form fields
Referral program
Report a typo
Write HTML and CSS code
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Referrals</title>
</head>
<body>
<h2>Referral Program</h2>
<form action="process_referral.php" method="POST">
<input name="referrer_546" value="ref_alex" id="referral">
<label for="email">Friend's Email:</label>
<input type="email" id="email" name="email" required>
<input type="submit" value="Refer a Friend">
</form>
</body>
</html>
Completed 1 of 2
Implement hidden form field in referrer tag.
The code is valid.
___
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.
Create a free account to access the full topic
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.