Page 1 of 1
descargar fichero desde un servidor Https
Posted: Thu Sep 19, 2013 2:59 pm
by lucasdebeltran
Amigos,
¿Alguien lo ha conseguido descargar desde
https://www.myserver.com/dato.txt?.
Muchas gracias.
Re: descargar fichero desde un servidor Https
Posted: Thu Sep 19, 2013 5:37 pm
by Joel Andujo
Amigo a mi me funciona al 100% esto con xHarbour :
cHttp:='
https://www.myserver.com/dato.txt'
if !URLDownLoad(cHttp, 'c:\MisDescargas\Respuesta.txt')
mensaje('Error : '+cHttp)
else
? memoread('c:\MisDescargas\Respuesta.txt')
endif
*----------------------------*
func URLDownLoad(cUrl, cSaveAs)
hLib = LOADLIBRARY( "urlmon.dll")
if !URLDownloadToFile( 0, cUrl, cSaveAs, 0, 0 ) == 0
retu.f.
endif
FREELIBRARY( hLib )
retu.t.
DLL32 FUNCTION URLDownloadToFile(pCaller AS LONG,szURL AS STRING, szFileName AS STRING, dwReserved AS LONG, lpfnCB AS LONG);
AS LONG PASCAL;
FROM "URLDownloadToFileA";
LIB hlib
Re: descargar fichero desde un servidor Https
Posted: Thu Sep 19, 2013 8:16 pm
by russimicro
oUrl := tURL():New(http+cDirSer+"/zerusbas.rar" )
oClient := tIPClientHTTP():New( oUrl )
oClient:nConnTimeout := nSegEsp
IF oClient:Open( oUrl )
oClient:ReadToFile( cRutDes+"zerusbas.rar",nil,nil,"no borra chr(13)")
oClient:Close()
ELSE
MYMEN("Error. No fue posible conectarse al servidor "+cNomSer)
meter(9)
return
ENDIF
Re: descargar fichero desde un servidor Https
Posted: Thu Sep 19, 2013 8:49 pm
by lucasdebeltran
Hola,
Muchas gracias.
URLDownloadToFile es lo que utilizaba, pero en Windows 8 falla bastante sin motivo aparente.
Y tIPClientHTTP():New( oUrl ) no funciona con HTTPS.
Re: descargar fichero desde un servidor Https
Posted: Thu May 22, 2014 7:29 pm
by elmoiquique
lucasdebeltran wrote:Hola,
Muchas gracias.
URLDownloadToFile es lo que utilizaba, pero en Windows 8 falla bastante sin motivo aparente.
Y tIPClientHTTP():New( oUrl ) no funciona con HTTPS.
Sabes cual es la funcion que reemplaza al TIPCLIENTHTTP() para lo https
Re: descargar fichero desde un servidor Https
Posted: Mon May 26, 2014 6:47 pm
by José Vicente Beltrán
Otra alternativa es 'wget.exe', yo lo uso desde hace tiempo por un consejo de alguien de este foro y funciona muy bien, probado en XP, W7 y W8.1 tanto con HTTP como con HTTPS
Code: Select all
waitRun( "wget.exe -q -r -t6 --no-check-certificate miurl\miarchivo.txt -O c:\miarchivo.txt", 0 )
Saludos
Re: descargar fichero desde un servidor Https
Posted: Fri Dec 19, 2014 1:58 pm
by jesusdelamora
QUE VERSION DE WGET USAS ?
Re: descargar fichero desde un servidor Https
Posted: Sun Dec 21, 2014 4:07 pm
by José Vicente Beltrán
Hola
wGet v.1.15
Saludos