how can I tell WordPress, that if a user registers, it shall execute my function?
You can use user_register action hook which fires after a user has registered and passes $user_id as a variable:
//do your stuff
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
5 years ago