Author: admin
-
PHP Operators
What is Operators in PHP Operators are symbols that tell the PHP processor to perform certain actions. For example, the addition (+) symbol is an operator that tells PHP to add two variables or values, while the greater-than (>) symbol is an operator that tells PHP to compare two values. The following lists describe the…
-
PHP Strings
What is String in PHP A string is a sequence of letters, numbers, special characters and arithmetic values or combination of all. The simplest way to create a string is to enclose the string literal (i.e. string characters) in single quotation marks (‘), like this: $my_string = ‘Hello World’; You can also use double quotation marks…
-
PHP Data Types
Data Types in PHP The values assigned to a PHP variable may be of different data types including simple string and numeric types to more complex data types like arrays and objects. PHP supports total eight primitive data types: Integer, Floating point number or Float, String, Booleans, Array, Object, resource and NULL. These data types…
-
PHP Echo and Print Statements
The PHP echo Statement The echo statement can output one or more strings. In general terms, the echo statement can display anything that can be displayed to the browser, such as string, numbers, variables values, the results of expressions etc. Since echo is a language construct not actually a function (like if statement), you can use it…
-
PHP Constants
What is Constant in PHP A constant is a name or an identifier for a fixed value. Constant are like variables, except that once they are defined, they cannot be undefined or changed (except magic constants). Constants are very useful for storing data that doesn’t change while the script is running. Common examples of such data…
-
PHP Constants
What is Constant in PHP A constant is a name or an identifier for a fixed value. Constant are like variables, except that once they are defined, they cannot be undefined or changed (except magic constants). Constants are very useful for storing data that doesn’t change while the script is running. Common examples of such data…
-
PHP Variables
What is Variable in PHP Variables are used to store data, like string of text, numbers, etc. Variable values can change over the course of a script. Here’re some important things to know about variables: In PHP variable can be declared as: $var_name = value; Example In the above example we have created two variables where…
-
PHP Syntax
Standard PHP Syntax A PHP script starts with the <?php and ends with the ?> tag. The PHP delimiter <?php and ?> in the following example simply tells the PHP engine to treat the enclosed code block as PHP code, rather than simple HTML. Example Every PHP statement end with a semicolon (;) — this tells the PHP engine that the end of…
-
PHP Getting Started
Getting Started with PHP Here, you will learn how easy it is to create dynamic web pages using PHP. Before begin, be sure to have a code editor and some working knowledge of HTML and CSS. If you’re just starting out in web development, start learning from here » Well, let’s get straight into it. Setting…
-
PHP Tutorial
PHP stands for Hypertext Preprocessor. PHP is a very popular and widely-used open source server-side scripting language to write dynamically generated web pages. PHP was originally created by Rasmus Lerdorf in 1994. It was initially known as Personal Home Page. PHP scripts are executed on the server and the result is sent to the web…