- Код: Выделить всё
Private Sub wsFileFetch_Connect()
Dim PASS, URLS, Estimated As String
If frmAddFile.cmbFileDownload.Text = "Немедленно" Then
Estimated = 1
Else
Estimated = ""
End If
Parameters = "url=" & frmAddFile.txtAddress & vbCrLf _
& "filename=" & frmAddFile.txtFileRename & vbCrLf _
& "estimated=" & Estimated & vbCrLf _
& "description=" & frmAddFile.txtDescription & vbCrLf _
& "submit=Fetch" & vbCrLf
PASS = Base64Decoder.Encode(frmSettings.txtLogin & ":" & frmSettings.txtPassword)
URLS = "POST /somefolder/somescript.php HTTP/1.0" & vbCrLf _
& "Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, " _
& "application/vnd.ms-excel, application/msword, application/x-shockwave-flash, */*" _
& vbCrLf _
& "Referer: http://someserver/somefolder/somescript.php" & vbCrLf _
& "Accept-Language: ru" & vbCrLf _
& "Content-Type: application/x-www-form-urlencoded" & vbCrLf _
& "Accept-Encoding: gzip, deflate" & vbCrLf _
& "User-Agent: Mozilla/4.0 (compatible; MSIE 5.5; Windows NT 5.0;" _
& " MyIE2) " & vbCrLf _
& "Host: someserver" & vbCrLf _
& "Content-Length: " & Len(Parameters) & vbCrLf _
& "Pragma: no-cache" & vbCrLf _
& "Authorization: Basic " & PASS & vbCrLf _
& "Connection: Keep-Alive" & vbCrLf & vbCrLf _
& Parameters
frmAddFile.txtDescription.Text = URLS
frmMain.wsFileFetch.SendData URLS
'MsgBox ("Winsock Connected")
'wsFileFetch.Close
End Sub
Скрипт в ответ возвращает:
- Код: Выделить всё
<HTML>
<LINK REL=STYLESHEET TYPE="text/css" HREF="style.css">
<script>
function openwindow(url){
Mywindow = window.open(url,'','height=160,width=220,status=no,toolbar=no,menubar=no,location=no');
}
</script>
<body>
Это сообщение об ошибке. Как его можно просмотреть?
Спасибо.