Ftp woes

Tim tim11 at bellatlantic.net
Tue Apr 23 02:59:01 EDT 2002


Thanks again Dave! That was even more than I had expected. Great
functionality with download status. This will allow me to share one stack on
different platforms so that it's always updated. I'm assuming that download
status could be implemented for uploading as well.
-- 
Tim


On 4/23/02 2:51 AM, "Dave Cragg" <dcragg at lacscentre.co.uk> wrote:

> At 1:51 am -0400 23/4/02, Tim wrote:
> 
>> That did it. Thanks a bunch! Is there a way to reverse engineer this so that
>> a shell stack could open this TestStack from the ftp server?
> 
> This will do it.
> 
> put "myusername at domain.com" into tName
> put "ftp://" & urlEncode(tName) & ":mypassword" & "@" into tUrl
> put "ftp.business.earthlink.net/www/TestStack" after tUrl
> go stack decompress(url tUrl)
> 
> If it's a large stack and you want to show some kind of download
> status, consider using "load url" instead. Something like:
> 
> on mouseUp
> put "myusername at domain.com" into tName
> put "ftp://" & urlEncode(tName) & ":mypassword" & "@" into tUrl
> put "ftp.business.earthlink.net/www/TestStack" after tUrl
> load url tUrl with message "stackLoaded"
> send "showProgress" && quote & tUrl & quote to me in 100 milliseconds
> end mouseUp
> 
> on showProgress pUrl
>  if urlStatus(pUrl) is not among the items of "error,timeout,cached" then
>   put urlStatus(pUrl) into field "status" ##or something sexier
>   send "showProgress" && quote & pUrl & quote to me in 100 milliseconds
>  end if
> end showProgress
> 
> on stackLoaded pUrl, pStatus
> if pStatus is "cached" then
>   go stack decompress(url pUrl)
>   unload url pUrl ##assuming you don't need it again
> else
>  #some error message here
>  unload url pUrl
> end if
> end stackLoaded
> 
> Cheers
> Dave Cragg
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> http://lists.runrev.com/mailman/listinfo/use-revolution




More information about the use-livecode mailing list