Correct Answer: Yes we can use include("xyzphp") more than one time in any page but it create a prob when xyzphp file contain some funtions declaration then error will come for already declared function in this file else not a prob like if you want to show same content two time in page then must incude it two time not a prob
Correct Answer: htaccess is a configuration file running on Apache serverThese htaccess file used to change the functionality and features of apache web server eg htaccess file used for url rewrite htaccess file used to make the site password protected htaccess file can restrict some ip addresses ,so that on restricted ip adresses site will not open
Correct Answer: Calculate the md5 hash of a string The hash is a 32-character hexadecimal number I use it to generate keys which I use to identify users etc If I add random no techniques to it the md5 generated now will be totally different for the same string I am using
7. What are the differences between GET and POST methods in form submitting?
Correct Answer: On the server side, the main difference between GET and POST is where the submitted is stored The $_GET array stores data submitted by the GET method The $_POST array stores data submitted by the POST method On the browser side, the difference is that data submitted by the GET method will be displayed in the browser?s address field Data submitted by the POST method will not be displayed anywhere on the browser GET method is mostly used for submitting a small amount and less sensitive data POST method is mostly used for submitting a large amount or sensitive data
Correct Answer: A session is a logical object created by the PHP engine to allow you to preserve data across subsequent HTTP requests Sessions are commonly used to store temporary data to allow multiple PHP pages to offer a complete functional transaction for the same visitor
9. How do you destroy a particular or all Sessions?
Correct Answer: include() The include() function takes all the content in a specified file and includes it in the current file If an error occurs, the include() function generates a warning, but the script will continue execution include_once() File will not be included more than once If we want to include a file once only and further calling of the file will be ignored then we have to use the PHP function include_once() require() The require() function is identical to include(), except that it handles errors differently The require() generates a fatal error, and the script will stop require_once() The required file is called only once when a page is open and further calling of the file will be ignored