Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
Hi all,
I'm fairly new to PHP and I've been trying to get an FTP upload feacture working. So far I've got the code that will upload it, but on the page I want some feedback as it doess things, however, I don't get anything back until the while page has finished. I was wondering if there was a way of doing this.Code: Select all
echo "Attempting to connect to $mysql_result[url]<br/>";
// open a ftp connection
$connection_id = ftp_connect($mysql_result['url'], $mysql_result['port']);
if (!$connection_id)
{
echo "Can't connect to FTP server<br/><br/>";
}
else
{
echo "Connected, now logging in<br/>";
// login to the server
$login_response = ftp_login($connection_id, $mysql_result['user'], $mysql_result['pass']);
if (!$login_response)
{
echo "Can't login to FTP server<br/><br/>";
}Any help or pointers are welcomed
Thanks
Weirdan | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]