
Welcome to MysqlPhpTutorial.com, the weblog where we discuss about php programming and development by creating easy to learn php tutorials.
Functions, sessions, arrays, classes and forms - a overwhelming amount of information you need to absorb in order to perform better as a coder.
We believe that php examples presented on the site will boost your coding knowledges and help you develop performant, secure php applications.
Here are some of string comparation php functions:
Finding the position of a string or substring can be made with this php functions:
This is another PHP sef function, much better to use in case you want to get remove characters that are not a-z, 0-9, dash, underscore or space, then remove all leading and trailing spaces, change all dashes, underscores and spaces to dashes and return the modified string in lower case.
(more…)
There are some differences between echo and print in php, echo and print are not functions.
First, you can pass more than one parameter to echo, print doesn’t allow more than one parameter.
Example:
Now, let’s see something interesting…
First, you use \ (backslash) character to treat $a as a string not variable. Then, this is important, the code will be executed in this manner: first is executed print then echo. You may ask but why it will output “1″… Let’s see the next example:
Remember that print($arg) will return 1!
As you can see, it will output 51 because php print is executed first (5) and with echo returns 1.