PHP File
Use the fopen() function to open files in PHP. The first parameter of this function is the file to be opened and the second parameter specifies in which mode the file should be opened:
1
2
3
4
5
6
7
8
9
10
11
12
13
<html>
<body>
<?php
$file=fopen("welcome.txt","r");
?>
</body>
</html>
The ...
AJAX RESPONSE XML
The most important advantage of XML is that it’s the most easily readable format for other humans. A secondary advantage is that XML has been around for quite a while and that ...
PHP Include
The include() or require() function allows to insert the content of one PHP file into another PHP file before the server executes it. These two functions are used to create functions, ...
How to Destroying a Session?
If you wish to delete some session data, you can use the unset() or the session_destroy() function.
The unset() function is used to free the specified session variable:
<?php
unset($_SESSION['views']);
?>
You ...
PHP Sessions
A PHP session variable is used to store information about, or change settings for a user session. Session variables hold information about one single user, and are available to all ...
PHP ERROR
Error handling is an important part of creating web applications.
There are three different error handling methods:
Simple “die()” statements
Custom errors and error triggers
Error ...
