PHP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesPHP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #1  
Old May 8th, 2008, 02:48 PM
JavaNinja's Avatar
JavaNinja JavaNinja is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Location: in the ether
Posts: 386 JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level)JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level)JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level)JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level)JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level)JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 5 Days 4 h 34 m 40 sec
Reputation Power: 31
PHP5 - Write file to another server

Hello all,

Is it possible with PHP to write a file to another server?

I am aware you can transfer files to another server by using ftp etc. I don't want to have any copy of the file that i need written on my server. If PHP can't do, is there anything else that can?

Thanks all

Reply With Quote
  #2  
Old May 8th, 2008, 03:11 PM
Stew_McGruff's Avatar
Stew_McGruff Stew_McGruff is offline
PHP Wacko
Dev Shed Novice (500 - 999 posts)
 
Join Date: Sep 2003
Location: Washington DC
Posts: 974 Stew_McGruff User rank is Second Lieutenant (5000 - 10000 Reputation Level)Stew_McGruff User rank is Second Lieutenant (5000 - 10000 Reputation Level)Stew_McGruff User rank is Second Lieutenant (5000 - 10000 Reputation Level)Stew_McGruff User rank is Second Lieutenant (5000 - 10000 Reputation Level)Stew_McGruff User rank is Second Lieutenant (5000 - 10000 Reputation Level)Stew_McGruff User rank is Second Lieutenant (5000 - 10000 Reputation Level)Stew_McGruff User rank is Second Lieutenant (5000 - 10000 Reputation Level) 
Time spent in forums: 1 Week 5 Days 23 h 25 m 2 sec
Reputation Power: 70
It really depends on what services are running on the other server, and what you have access to. ftp would be my first choice, if that wasn't available, I'd look into using exec to call scp command (I'm making the assumption your on linux here). If that was available, next I'd look into setting up a web page on the other server to handle file uploads, then use curl for doing the upload.
__________________
"I'm working so I won't have to try so hard" - the strokes

my blog

security articles I recommend:
SQL Injection Attacks
XSS
CSRF

Reply With Quote
  #3  
Old May 8th, 2008, 03:35 PM
JavaNinja's Avatar
JavaNinja JavaNinja is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Location: in the ether
Posts: 386 JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level)JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level)JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level)JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level)JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level)JavaNinja User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 5 Days 4 h 34 m 40 sec
Reputation Power: 31
Quote:
Originally Posted by Stew_McGruff
It really depends on what services are running on the other server, and what you have access to. ftp would be my first choice, if that wasn't available, I'd look into using exec to call scp command (I'm making the assumption your on linux here). If that was available, next I'd look into setting up a web page on the other server to handle file uploads, then use curl for doing the upload.

FTP - means that i have to actually have a copy of the file on my server and then send it. I don't want to keep copies, or even expend the effort to delete them after i use (send) them!

Exec() - I am on a linux server and i think this is the best idea so far. What commands would you use though?

CURL - Creating a page on the other server..hmm..Not sure about this since i may have to deal with many servers. I can't keep creating pages. But i guess i can use the first option and use ftp to send this file (initially, once) and then from then on use CURL!! What do you think?

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPHP Development > PHP5 - Write file to another server


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

 Free IT White Papers!
 
Accelerating Trading Partner Performance
One in five. That's how many partner transactions have at least one error. That is an amazing statistic, particularly given the extraordinary leaps in innovation across the global supply chain during the past two decades. Download this white paper to learn more.

 
Competing on Analytics
This Tech Analysis is designed to help identify characteristics shared by analytics competitors, and includes information about 32 organizations that have made a commitment to quantitative, fact-based analysis.

 
Cost Effective Scaling with Virtualization and Coyote Point Systems
An overview of the industry trend toward virtualization, how server consolidation has increased the importance of application uptime and the steps being taken to integrate load balancing technology with virtualized servers.

 
Five Checkpoints to Implementing IP Telephony
Implementation planning for IP PBX software and IP telephony has become vital as businesses replace discontinued legacy PBX phone systems. This informative whitepaper outlines five "checkpoints" for any implementation plan that will help make IP communications a successful proposition.

 
Hosted Email Security: Staying Ahead of New Threats
In the last two years, email has become a fierce battleground between the nefarious forces of spam and malware, and the heroes of messaging protection. The spam volumes increased alarmingly every month, bringing clever new forms of phishing and virus propagation attacks.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway