Advertisement
cheungtifan

Untitled

May 18th, 2012
350
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.30 KB | None | 0 0
  1. <?php
  2. function upload_to_cdn($filename) {
  3.     $username = get_conf('cdn_username');
  4.     $password = get_conf('cdn_password');
  5.     $remote = get_conf('cdn_remote_host');
  6.     $new_path = relpath($filename, get_conf('document_root'));
  7.     ftp_upload($filename, $newpath, $remote, $username, $password);
  8. }
  9. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement