Hi everyone, welcome to PHP tutorial in Khmer. Today we talk about PHP variables
and PHP data types.
This post is PHP khmer tutorial for all beginner in PHP programming and PHP basics. So, let we start!
If you want to learn more, please check our: [PHP Tutorial in Khmer Playlist].
String: String is text data.
Integer: Integer is number without dot.
Float (Double): Float is number with dot.
Boolean: Boolean is true or false.
Array: Array is many values in one variable.
You can get each value with index number.
Object: Object is advanced type but useful in PHP programming. Not cover in
this tutorial yet.
PHP variables:
Variables let you store data and use it many time in your website.
Data types
Data types help you know what kind of data you work with like when you add
number, you must use integer or float, not string.
So, PHP basics like these is important for any PHP khmer tutorial.
Start PHP with VS Code :Back 👈 👉 Next:PHP Control Structures
Free Khmer Ebook Download (PDF): Database | Microsoft Access | Python Programming
This post is PHP khmer tutorial for all beginner in PHP programming and PHP basics. So, let we start!
If you want to learn more, please check our: [PHP Tutorial in Khmer Playlist].

What is PHP Variable?
PHP variable is like box to store information. Variable name must start with dollar sign ($) like:
$myVar = "Hello world!"; $age = 25;
PHP Data Types
PHP data types is type of data you put inside variable box. There are many types in PHP khmer tutorial:
$greet = "Hello, PHP in Khmer!";
$number = 100;
$price = 101.99;
$isValid = true;
is_working = false;
$colors = array("red", "blue", "green");
You can get each value with index number.
How to Use PHP Variables and Data Types in khmer, see in video below
Why Use PHP Variables and Data Types?
So, PHP basics like these is important for any PHP khmer tutorial.
Start PHP with VS Code :Back 👈 👉 Next:PHP Control Structures
Free Khmer Ebook Download (PDF): Database | Microsoft Access | Python Programming