Hey man,
I'm an electronics engineering student and my final year project was an IoT project where I used an Arduino interfaced with a router/switch to turn the lights on/off (and additional things) in a room. The user has to log into a webpage written primarily in PHP (connects to a MySQL database) and this page, which can be accessed from any device connected to the LAN, is where the virtual switches are.
My project was a success and I think I have what it takes to guide you through the entire process. Hope you'll pick me ;)
Cheers.