Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <head>
- <script>
- function roepPhpFunctieAan() {
- var xmlHttp = null;
- xmlHttp = new XMLHttpRequest();
- var params = "?intensiteit=100";
- xmlHttp.open("GET", "http://localhost/controlled.php" + params, false);
- xmlHttp.onreadystatechange = function() {// Call a function when the state changes.
- if (xmlHttp.readyState == 4 && xmlHttp.status == 200) {
- alert(xmlHttp.responseText);
- }
- }
- xmlHttp.send();
- }
- </script>
- </head>
- <body>
- <button onclick="roepPhpFunctieAan()">Zet aan</button>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement