Combining HTML and PHP Code on a Single Page Write PHP code with HTML code on a single page as on hard copy. More flexibility to write the entire page dynamically. For this use a PHP_SELF variable is in the action field of the <form> tag. The action field of the FORM instructs where to submit the form data when the user presses the “submit” button. Th…
Read moreAccessing Form Input with User-Defined Arrays or Working with PHP and arrays of data Supergloabal variable is a pre-defined associative array created by PHP that holds all input data submitted to a PHP script via the GET or POST method. One can have arrays created in $_GET / $_POST by using a square-bracket syntax when specifying the name attribute for…
Read moreCreating a Simple Input Form
Read moreLooping and counting in string Iteration through the characters of a string. The function count takes a string as its parameter. The for statement iterates through each character in the string and checks if the character is equal to the value of Char. If so, the counting variable, count, is incremented by one. When all characters have been processed, the c…
Read moreString comparison is performed using the characters in both strings. The characters in both strings are compared one by one. When different characters are found then their Unicode value is compared. The character with lower Unicode value is considered to be smaller so all the uppercase letters come before all the lowercase letters. Example :- fruit1 = …
Read more
Social Plugin