Redirecting people to a different web page is a simple process. You can do it with a script that runs on the server, and there are many examples of ready-made scripts available. Redirecting different people to specific urls based on a code number that's entered on a web page is not so easy for a beginner however.
You'll need to tell the script to look at a database of codes, and refer the user to the correct page for the code used. How many different codes/pages are we talking about here?