Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Script php untuk transfer file antar hostingan atau cPanel tanpa harus download ke computer terlebih dahulu
- <?php
- system("https://wordpress.org/latest.zip");
- ?>
- kalau fungsi systemnya di disabled ama hosternya, anda bisa gunakan fungsi curl
- <?php
- $ch = curl_init("https://wordpress.org/latest.zip");
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
- curl_setopt($ch, CURLOPT_BINARYTRANSFER, true);
- $output = curl_exec($ch);
- $fh = fopen("latest.zip", 'w');
- fwrite($fh, $output);
- fclose($fh);
- ?>
- kalau fungsi curlnya juga didisabled, anda bisa gunakan fungsi file_get_contents
- <?php
- $output = file_get_contents("https://wordpress.org/latest.zip");
- $fh = fopen("latest.zip", 'w');
- fwrite($fh, $output);
- fclose($fh);
- ?>
Add Comment
Please, Sign In to add comment