There are some certain ways to send your information or data to the PHP page- Using Form Methods – Get & Post Using Cookies & Session Using Query String / URL Rewriting Using Hidden form fieldForm MethodsThe GET Method: The GET method sends information separated by the ? Operator.Example: http://www.xyz.com/home.html?city=Gurgaon Please note that the GET…
Read MoreError handling is the process of catching errors from the program and then taking appropriate action. Before proceeding for error handling you should get to know how many types of errors occurred in PHP. Notices: These are non-critical errors that occurred while executing a script – for example, accessing a variable that has not yet…
Read MoreString functions are the most important functions frequently used in PHP. String is the sequence of characters, like “Let’s learn String functions”. There is no installation required to use string function. Example <?php $name = “Hirdesh Bhardwaj”; print($name); ?> String Concatenation Operator To concatenate two string variables together, we use the dot (.) operator −…
Read MoreOOP is intimidating to a lot of developers because it introduces new syntax and, at a glance, appears to be far more complex than simple procedural, or inline, code. However, upon closer inspection, OOP is actually a very straightforward and ultimately simpler approach to programming. Before we go in details, let’s define important terms related…
Read MoreWe need to create an HTML form that allows you to choose the file to be uploaded. Note: please make sure you have form method type is post and enctype=”mutipart/form-data” to to handle file uploading process successfully. HTML Code <form enctype=”multipart/form-data” action=”process.php” method=”POST”> Choose File : <input name=”myfile” type=”file” /> <input type=”submit” value=”Upload” /> </form>…
Read MoreAlmost in every web application sending automated email by system is the common requirement. So, it’s very common and important part that must be known by developer. The simple example, when a visitor to your website fills out a enquiry form. mail function return a boolen value, return true if email sent successfully, false otherwise…
Read MoreThe basic task of both cookies and sessions is to store visitor data so that it can be accessed by every page on a website. Cookies: Cookies are small text files that are stored in the visitor’s browser for a specific time or for a long -lifespan. Cookies can be edited by the visitor. in…
Read MoreThe Include() and require() statements are used to insert codes written in other files, in the flow of execution. The main of using include and require functions to integrate one page code or content into another page. You can maintain usually some repeated functionality in the form of PHP file and finally you can call…
Read MoreAjax (Asynchronous Java script And XML) Introduction In Jesse Garrett’s original article that coined the term, it was AJAX. The “X” in AJAX really stands for XML HTTP Request though, and not XML. Jesse later conceded that Ajax should be a word and not an acronym and updated his article to reflect his change in heart. So “Ajax”…
Read MoreDifference Between while and do…while Loop: With a while loop, the condition to be evaluated is tested at the beginning of each loop statement, so if the conditional expression evaluates to false, the loop will never be executed. With a do-while loop, on the other hand, the loop will always be executed once, even if…
Read More