Что нового

Как взять текст из value

tar

Новичок
Сообщения
58
Репутация
0
Здравствуйте. Помогите взять со страницы "[email protected]"
вот отсюда:
Код:
<input id="mail" onclick="select(this);" data-original-title="Ваш временный Email адрес" class="mail opentip" value="[email protected]" data-placement="bottom" title="" type="text" readonly="">
Сохраняется только дата без майл адреса
Код:
#include <IE.au3>
#include <file.au3>
$sUrl= 'https://temp-mail.org/ru/'
$oIE = _IECreate($sUrl, 0, 1, 0)
_IELoadWaitTimeout(5000)
_IELoadWait($oIE)
$sText = ""
$elems = _IETagNameGetCollection($oIE, "input")
If IsObj($elems) Then
For $elem In $elems
If StringInStr($elem.className, "mail opentip") Then
$sText = $elem.innerTEXT
ExitLoop
EndIf
Next
EndIf
MsgBox(0, "text", $sText)
_FileWriteLog(@ScriptDir & "\text.txt", $sText)
 

CreatoR

Must AutoIt!
Команда форума
Администратор
Сообщения
8,671
Репутация
2,481
Код:
#include <IE.au3>

$sUrl = 'https://temp-mail.org/ru/'
$oIE = _IECreate($sUrl, 0, 1, 0)
_IELoadWaitTimeout(5000)
_IELoadWait($oIE)

$sText = ""
$oMail = _IEGetObjById($oIE, "mail")

If IsObj($oMail) Then
	$sText = $oMail.Value
EndIf

MsgBox(0, "text", $sText)
 
Верх