Searching for "u"

Q:

What is Apache configuration file typically called?

Answer

The Apache configuration file is called httpd.conf.

Report Error

View answer Workspace Report Error Discuss

Subject: PHP

Q:

What is PHP's configuration file called?

Answer

PHP’s configuration file is called php.ini.

Report Error

View answer Workspace Report Error Discuss

Subject: PHP

Q:

What is Constructors and Destructors?

Answer

CONSTRUCTOR : PHP allows developers to declare constructor methods for classes. Classes which have a constructor method call this method on each newly-created object, so it is suitable for any initialization that the object may need before it is used.

DESTRUCTORS : PHP 5 introduces a destructor concept similar to that of other object-oriented languages, such as C++. The destructor method will be called as soon as all references to a particular object are removed or when the object is explicitly destroyed or in any order in shutdown sequence.

Report Error

View answer Workspace Report Error Discuss

Subject: PHP

Q:

Explain $_FILES Superglobal Array.

Answer

Array                                              Descriptions
--------------------------------           -----------------------------------
$_FILES['userfile']['name']              The original name of the file on the client machine.




$_FILES['userfile']['type']                The MIME type of the file if the browser provided 


                                                   this information. An example would be "image/gif".




$_FILES['userfile']['size']                The size, in bytes, of the uploaded file.




$_FILES['userfile']['tmp_name']      The temporary filename of the file in which the


                                                  uploaded file was stored on the server.




$_FILES['userfile']['error']              The error code  associated with this file upload.

Report Error

View answer Workspace Report Error Discuss

Subject: PHP

Q:

How to store the uploaded file to the final location?

Answer

move_uploaded_file( string filename, string destination)

Report Error

View answer Workspace Report Error Discuss

Subject: PHP

Q:

How can we know the number of days between two given dates using php?

Answer

<?php
$tomorrow = mktime(0, 0, 0, date("m") , date("d")+1, date("Y"));
$lastmonth = mktime(0, 0, 0, date("m")-1, date("d"), date("Y"));
echo ($tomorrow-$lastmonth)/86400;
?>

Report Error

View answer Workspace Report Error Discuss

Subject: PHP

Q:

What are encryption functions in PHP?

Answer

CRYPT(), MD5()

Report Error

View answer Workspace Report Error Discuss

Subject: PHP

Q:

What is the functionality of the function strstr and stristr?

Answer

strstr() returns part of a given string from the first occurrence of a given substring to the end of the string.
For example:
strstr("user@example.com","@") will return "@example.com".

stristr() is idential to strstr() except that it is case insensitive.

Report Error

View answer Workspace Report Error Discuss

Subject: PHP