Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
How To Copy a File
How To Copy a File? - PHP Script Tips - Working with Directoris and Files
✍: FYIcenter.com
If you have a file and want to make a copy to create a new file, you can use the copy() function. Here is a PHP script example on how to use copy():
<?php
unlink("/temp/myPing.exe");
copy("/windows/system32/ping.exe", "/temp/myPing.exe");
if (file_exists("/temp/myPing.exe")) {
print("A copy of ping.exe is created.\n");
}
?>
This script will print:
A copy of ping.exe is created.
2007-04-23, 5346👍, 0💬
Popular Posts:
How do you override a defined macro? You can use the #undef preprocessor directive to undefine (over...
What is AL.EXE and RESGEN.EXE? In the previous question you have seen how we can use resource files ...
What will be printed as the result of the operation below: main() { int x=10, y=15; x = x++; y = ++y...
Would I use print "$a dollars" or "{$a} dollars" to print out the amount of dollars in this example?...
How To Create an Add-to-NewsGator Button on Your Website? - RSS FAQs - Adding Your Feeds to RSS News...