What is the difference b/w $i and $$i?
The main difference b/n $i and $$i is that $i is an variable where $$i is an reference variable.
What is the difference b/w PHP4 and PHP5?
The main difference b/w PHP4 and PHP5 are given below:
1.Generally,Both are same.PHP5 is a new version of PHP4.So,PHP5 has some improvement in design, security, and stability.
2.OOPS is used in PHP4 as well, with the difference that in PHP5 things are a little more evaluated.So, In PHP4 safety modes for classes (public, private) are not accepted.Reply
What is the substitution of submit in PHP?
We can do that by using one these of methods:
2.By using CURL functions
3.By using header
header("Location: page.php") Reply
What is .htaccessfile and how to use them?
If we write an address in the address bar in our browser, system receives those files displayed on browser.Web server is use to controls which types of files are displayed.
I have given you two most popular sides, these are IIS and Apache.
paths to files (directories) are specified from the server root.
domains with protocols specified. Reply
How we use Error logging error handling method in PHP?
In PHP,by default an error log send to the error log system.By using error logging we can send and error log to the specific file.
We checked this by using an example.In this we send a mail to our self with error message.And the scripts does not work when error comes.
//error handler function
function customError($errorno, $errorstr)
echo "<b>Error:</b> [$errno] $errorstr<br />";
echo "program has been notified";
error_log("Error: [$errorno] $errorstr",1,
//set error handler
trigger_error("I should be greater than 1", E_USER_WARNING);
 I should be greater than 1
program has been notified
Our mail have reply message like that,
Error:  I should be greater than 1Reply
How we use Custom errors and error triggers error handling method in PHP?
In Custom errors and error triggers,we handle errors by
using self made functions.
1.Custom errors : By using this can handle the multiple
errors that gives multiple message.
In this syntax if we want that our error handle, handle
only one error than we write only one argument otherwise
for handle multiple errors we can write multiple arguments.
//function made to handle errorfunction
echo \"<b>Error:</b> [$errorno] $errorstr\"; }
//set error handler like that
//trigger to that error
2.error trigger : In PHP we use error trigger to handle
those kind of error when user enter some input data.If
data has an error than handle by error trigger function.
trigger_error(\"I should be greater than 1 \");
In this trigger_error function generate error when i is
less than or greater than 1.
How you can differentiate abstract class and interface?
There are some main difference between abstract and interface are given below:
1.In an abstract we can use sharable code where in the case of interface their is no facility to use sharable code.
2.In which class we implement an interface class. All method that we use should be defined in interface. Where as class those extending an abstract while a class extending an abstract class their is no need to defined methods
in the abstract class. Reply
How we handle errors in PHP?Explain it?
In PHP we can handle errors easily.Because when error comes it gives error line with their respective line and send error message to the web browser.
When we creating any web application and scripts. We should handle errors wisely.Because when this not handle properly it can make bg hole in security.
In PHP we handle errors by using these methods:
1.Simple "die()" statements
2.Custom errors and error triggers
How we use Simple "die()" statements error handling method in PHP?
I have given you a example.In this we try to open a file.
Suppose if that file does not exist,Than this type of message comes.
fopen(R4R Welcome.txt) [function.fopen]: failed to open stream: No such file or directory in C:PHPWelcome.php on line 2
Now, we handle this error like that,
die("File does not exist");
If file does not exist than output comes like that, File does not existReply
What is use of the <f:subview>Tag in the JSF?
JSF <f:subview> Tag is help to dynamically includes another page from the same web application.Reply