Hi Guys,
I’m currently stuck on an issue i have which i will try and explain to the best of my ability and try and explain what I’m trying to achieve.
Right I’m in the middle of creating an affiliate network using PHP & MySQL. I have a table called Programs which looks like the following:
Now what im trying to do is do it so affiliates need to apply to the program in order to be able to run it. Now i’m trying to think of the best way in order to do this and one idea i had was to add 2 new fields in the table called Programs at the end and call them ‘PendingAffiliates’ and ‘ApprovedAffiliates’ and for example lets say affiliate id 2,7,24 and 29 applied to run programid 1 and affiliate id 1,3,4,5 where approved to run the program the table would now look like this:
Now the problem i have is i dont know what code i would use to check if the affiliateid was pending or approved to run that program because the value of pendingaffiliates and approvedaffiliates would have more than 1 value in them. Can you suggest a way of doing this or a better way of doing this please.
If you have any questions feel free to ask, any help would be great.
Thank you!