I'm using sockets.io, express and php and I was wondering if it is possible to push something of a page (that only a specific user can see at the time) to another page other can see. For example, if an admin has:
<?php $a = $row['test']; //data from test table $q = '<h2>'.$a.'</h2>'; $b = $row['options']; //data from answers table $c = '<label"><input type="radio" name="radio" value="'.$b.'" onclick="">'.$a.'</label> $output = ''.$a.','.$c.',<input type="submit" name="submit" value="submit">'; echo $output
So this outputs as a question with radio buttons as options for the client to choose from. Is it possible for this to be pushed to the client. Like the admin will push first question and then the next, etc. I'm new to webscokets but I'm getting a hang of it but this is really cracking my brain. Any ideas will be really helpful. At the moment, I'e gotten the normal user to be able to view the contents as set by the admin. Now, my problem is the admin controlling how the data is sent to the user/client. I have a button now that when a user presses next, the next data/question comes but I'd like for the admin to be able to control that. Like when the user submits the first data, the page loads and waits for the admin to push the next question.