问题
I need a way to make a php script that will launch on a certain page load that I do not own.
What I want to launch when the page is loaded is a modal that has a login screen.
For this to be possible I will need for tampermonkey
/greasemonkey
to run a php script(or something close to it) that will retrieve information from a sql server.
EDIT:
I would host my own sql server and users would login/register on to it. They would then use this login to hold their information.
回答1:
I'm not really 100% sure what you're asking for here, but it's impossible to run PHP scripts on external websites, as PHP is a server-side language.
You also can't retrieve information from another website's MySQL Database without the login information to said Database, as well as access permissions (Databases often have a whitelist, and if you're not on it, you can't access it even with the information).
I'd need a little more info on what you want though, if it's something else. Sorry!
来源:https://stackoverflow.com/questions/30010014/run-a-php-script-or-anything-similar-from-greasemonkey-tampermonkey