Internet and Network Commands

<< Click to Display Table of Contents >>

Navigation:  3. Script Language > Internet and Network > FTP. - and more >

Internet and Network Commands

FTP. - File Transfer Protocol Test Download

Previous Top Next


MiniRobotLanguage (MRL)

 

FTP.test download

FTP.tdl

Test a download link

 

 

Intention

 

This command can be used to test a download-link, if it works or not.

 

Here is what we get with a valid URL:

 

$$URL=http://download.microsoft.com/download/9/2/7/927A4802-FC1C-4A71-9A2D-2DCEAC11B266/KB2716433/SQLServer2008-KB2716433-x86.exe

FTP.tdl|$$URL|$$RES|$$TXT

PRT.$$TXT

MBX.$$RES

ENR.

 

graphic

 

 

Here we have a valid server and an invalid link:

 

$$URL=http://download.microsoft.com/downloax/SQLServer2008-KB2716433-x86.exe

FTP.tdl|$$URL|$$RES|$$TXT

PRT.$$TXT

MBX.$$RES

ENR.

 

graphic

 

 

Now we will use an phantasy server and see what we get:

 

$$URL=http://download.fa2.de/download/9/2/7/927A4802-FC1C-4A71-9A2D-2DCEAC11B266/KB2716433/SQLServer2008-KB2716433-x86.exe

FTP.tdl|$$URL|$$RES|$$TXT

PRT.$$TXT

MBX.$$RES

ENR.

 

graphic

 

At last we will specify an (invalid protocol) empty URL:

 

$$URL=

FTP.tdl|$$URL|$$RES|$$TXT

PRT.$$RES-$$TXT

MBX.Ready

ENR.

 

graphic

 

 

 

Syntax

 

 

FTP.tdl|P2[|P3][|P4]

 

 

Parameter Explanation

 

P2 - URL - that shall be tested

 

P3 - (optional) Variable for a numerical result on success or not.

         200 - is success, 404 - is resource not found, others see above.

 

P4 - (optional) Variable for a textual result on success or not.

         Details see above.

 

 

If you omit  the Stack will look somehow like this:

 

graphic

 

 

 

Example

 

'***********************************

' FTP.tdl.-DEMO

'***********************************

$$URL=http://download.microsoft.com/download/9/2/7/927A4802-FC1C-4A71-9A2D-2DCEAC11B266/KB2716433/SQLServer2008-KB2716433-x86.exe

FTP.tdl$$URL|$$RES|$$TXT

PRT.$$TXT

IVV.$$RES!200

  MBX.There was a problem ($$RES)

EIF.

ENR.

RET.

 

 

 

Remarks

 

-

 

 

Limitations:

 

-

 

 

See also:

 

    DLV. - Download-to-Variable

    CFU. - Copy-From-URL

    URL. - Split URL

    FTP. - File Transfer Protokoll

    fto - file transfer protocol

    tdl - Test Download

    tpw - test with password