Triggering GPIO of a ESP8266 webserver from another ESP8266

Why didn't you ask for help with the coding, instead of making the hardware more complex, and then asking for help with that? This is what's known as an "X-Y" problem. You are asking for help with Y when what you really need help with is X.