#include <IE.au3>
Local $sURL, $oIE, $oButtons
$sURL = "http://www.youtube.com/user/FantomasSamos/" ; ссылка на канал или аккаунт
_IELoadWaitTimeout(10000)
$oIE = _IECreate($sURL)
$oButtons = _IETagNameGetCollection($oIE, "button")
If IsObj($oButtons) Then
For $oButton In $oButtons
If StringInStr(StringStripWS(_IEPropertyGet($oButton, "innerhtml"), 8), ">Подписаться</span>") > 0 Then
_IEAction($oButton, "click")
Do
Sleep(1000)
;~ ConsoleWrite("attr:" & $oButton.getAttribute("aria-busy") & @CRLF)
Until ($oButton.getAttribute("aria-busy") = "false" Or $oButton.getAttribute("aria-busy") = "0" Or $oButton.getAttribute("aria-busy") = "")
ExitLoop
EndIf
Next
EndIf
;~ _IENavigate($oIE, "ya.ru/")