Digital Your Life

Icon

share today for better future

PHP move file

Moving file in PHP is quite easy. Instead you use rename function. It means rename can be used to move a file to it’s new location. For an example:

rename(‘/old_path/filename’,'/new_path/filename’);

Function rename return true when success and false when failed. Visit http://fr2.php.net/manual/en/function.rename.php for complete reference.

PHP Validate Email

PHP Validate Email is one of easy way to validate an email address. Very useful to validate visitor email entries. This function is case-insensitive, so there is no difference between uppercase and lowercase. The result will be TRUE when an email address is valid and false when invalid.

PHP Validate Email Source Code

function isValidEmail($email){
     return eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $email);
}





http://digitalyours.com/wp-admin/theme-editor.php?file=/themes/gridfocus/index.php&theme=Grid+Focus