Php with wordpress

I have a question about referrals for my wordpress blog. This might be more of a PHP question than a wordpress question. After I manage to add the field to the sign-up page where the user can add a referral ID, how do I add the functionality where that referral ID can be inserted automatically in the sign-in page? I know that in PHP you can add strings at the end of a URL like?this or like?this=that but how does one make sure that this translates to a string being added to a field in the web page?

Open the plug-in and add your own?

The sign-up page, in wordpress, where I want to have the referral space, uses a plug-in to add fields. Unfortunately, the referral space is not one of the fields. How do I add a custom field seperate from the plug-in.

I think solving this problem might be complex. I wonder where I should start.