Home » Php » html – Writing a basic php script

html – Writing a basic php script

Posted by: admin February 25, 2020 Leave a comment

Questions:

I’m learning php but can’t get my first practice to work. Why?

https://codepen.io/adsler/pen/VwLaaKv

<!DOCTYPE html>
<html>
<body>

 <?php 

 echo  "hello world 1";

 ?>

</body>
</html>
How to&Answers:

As they mention in the comments you can’t run PHP in file protocol

you need to install localServer the easiest one called Xampp

or use in online editor prepared for PHP like this one jdoodle