私のクライアントは、ホストしていない、またはサーバーにアクセスできないサードパーティの Web サイトでアクションを実行するボタンを自分の Web サイトに配置したいと考えています。つまり、コードを HTML コードに埋め込む必要があります。
ボタンは公開されておらず、特定の従業員の一般的なログオンです。
<!doctype html>
<html>
<head>
<title>Add a Lead</title>
</head>
<script type="text/vbscript">
sub Execute()
Dim IE
Dim WRI
Set IE = CreateObject("InternetExplorer.Application")
IE.Visible = 1
IE.navigate "http://rentalapp.zillow.com/"
Do While (IE.Busy)
WScript.Sleep 10
Loop
Set WRI = IE.document.getElementByID("username")
WRI.Value = "username"
Set WRI = IE.document.getElementByID("password")
WRI.Value = "password"
Set WRI = IE.document.Forms(0)
WRI.Submit
WScript.Sleep 1000
IE.navigate "http://rentalapp.zillow.com/leads/add/"
end sub
</script>
<body>
<button onClick="Execute()">Add A Lead</button>
This is supposed to fire off the method called execute.
</body>
</html>