These are the simplest method to backup and restore the MySQl table
For taking the bakup of all the databases
mysqldump --user {user} --password {password} -A > {file name to dump}
To take the backup of a specific database
mysqldump --user {user} --password {password} dbname > {filename to dump}
To restore a SQL dump please use this
mysql --user {user} --password {password} dbName < {filename to restore}
www.w3answers.com
when we do the select queries that retrieve large data sets from MySQL, mysql_unbuffered_query in PHP is likely to give better performance than mysql_query.
PHP manual says, it “sends a SQL query query to MySQL, without fetching and buffering the result rows automatically”.
As you should be aware the HTTP protocol, as used for serving web pages, is completely stateless. This means that after the server has received a request, processed it and sent a response, the process which dealt with that request dies. Anything that the process had in its memory therefore dies with it, so when a subsequent request is received from the same client it is unable to refer to its memory about anything that happened previously.
Fortunately PHP provides a standard method of maintaining memory (state) between ....!
The Session Manager session support allows multiple server instances to share a common pool of sessions, known as a session cluster
Session clustering setting up methods :
#1)First methods, is to have a NFS shared where session will be store. Setting this is quite easy, just a little modification on php.ini file to change the “session.save_path ? directive to point to the NFS share. The main problem with NFS is on high traffic, NFS share is really slow. So synchronisation and data corruption can arrive and ....!
include()
The include() statement includes and evaluates the specified file. This also applies to require(). The two constructs are identical in every way except how they handle failure. include() produces a Warning while require() results in a Fatal Error. In other words, use require() if you want a missing file to halt processing of the page. include() does not behave this way, the script will continue regardless.
include_once()
The include_once() statement includes and evaluates the specified file during the execution ....!
The Session Manager session support allows multiple server instances to share a common pool of sessions, known as a session cluster
Session clustering setting up methods :
#1)First methods, is to have a NFS shared where session will be store. Setting this is quite easy, just a little modification on php.ini file to change the “session.save_path ? directive to point to the NFS share. The main problem with NFS is on high traffic, NFS share is really slow. So synchronisation and data corruption can arrive and ....!
Smarty is a template engine written in PHP. Typically, these templates will include variables —such as {$variable}— and a range of logical and loop operators to allow adaptability within of the template.
....!
<?php $banned = array("24.91.102.173", "64.21.162.113"); if (in_array($_SERVER['REMOTE_ADDR'], $banned)) { echo "You have been banned."; exit; } ?>
....!
Ans:
CHAR is a fixed length data type.
CHAR(n) will take n characters of storage even if you enter less than n characters to that column. For example, "answers" will be stored as "answers " in CHAR(10) column.
VARCHAR is a variable length data type.
VARCHAR(n) will take only the required storage for the actual number of characters entered to that column. For example, "answers" will be stored as "answers&q....!
Memcache is a technology which caches objects in memory where your web application can get to them really fast. It is used by sites such as Digg.com, Facebook.com and NowPublic.com and is widely recognized as an essential ingredient in scaling any LAMP application to handle enormous traffic.
....!
ANS:XMLHttpRequest
....!
1)Time triggered caching (expiry timestamp).
2)Content change triggered caching (sensitive content has changed, so cache must be updated).
3)Manually triggered caching (manually inform the application that information is outdated, and force a new cache creation).
....!
<?php$a = 1;$a = $a— + 1;echo $a;?>
A. 2B. 1C. 3D. 0E. Null
Answer B is correct.
....!
Answer: <?php $w3 = "mailto:info@w3answers.com"; preg_match('|.*@([^?]*)|', $w3, $w3output); echo $w3output[1]; ?>
....!
string urlencode(str)
where str contains a string like this “hello world” and the return value will be URL encoded and can be use to append with URLs, normaly used to appned data for GET like someurl.com?var=hello%world
string urldocode(str)
this will simple decode the GET variable’s valueLike it echo (urldecode($_GET_VARS[var])) will output “Hello world”
....!
string urlencode(str)
where str contains a string like this “hello world” and the return value will be URL encoded and can be use to append with URLs, normaly used to appned data for GET like someurl.com?var=hello%world
string urldocode(str)
this will simple decode the GET variable’s value
Like it echo (urldecode($_GET_VARS[var])) will output “Hello world”
....!
Recent comments
20 weeks 23 hours ago
13 weeks 1 day ago
23 weeks 1 day ago
23 weeks 4 days ago
28 weeks 15 hours ago
28 weeks 3 days ago
28 weeks 6 days ago
28 weeks 6 days ago
29 weeks 5 days ago
30 weeks 6 days ago