[Solved] Can’t call a JavaScript function on a php script


If you really want to go this approach…

while($row = mysqli_fetch_assoc($result)){

    if($row["temp"] < 27) {
        echo" <script>run()</script>";
    }
}

This should work.

2

solved Can’t call a JavaScript function on a php script