Sign in to follow this
Followers
0
-
Recently Browsing 0 members
No registered users viewing this page.
-
Similar Content
-
By Jahar
I have an AutoIT script It monitors 2 websites for content that applys to me and the services that I provide. One site is : www.Freelancer.com The other: www.PeoplePerHour.com Both sites publish new jobs on their site hourly or so. My AutoIT app, will view those sites and present new jobs to me in a grid that pops up on my screen. Lately, the app has stopped showing me any jobs from PeoplePerHour.
For freelancer.com, Inetget is giving full html but for peopleperhour, now its not coming.
Func _CheckPPH()
Local Static $hTimer = 0
Local Static $hDownload = 0
Local $aTitlesandUrls = 0
Local Static $sTempFile = ""
If $hTimer = 0 Then $hTimer = TimerInit()
If $hDownload = 0 Then
$sTempFile = _WinAPI_GetTempFileName(@TempDir)
ConsoleWrite("Checking PPH..." & @CRLF)
ConsoleWrite(">Downloading..." & @CRLF)
;~ $hDownload = InetGet("http://www.peopleperhour.com/freelance-jobs", $sTempFile, $INET_FORCERELOAD, $INET_DOWNLOADBACKGROUND)
$hDownload = InetGet("http://www.peopleperhour.com/freelance-jobs", $sTempFile, $INET_FORCERELOAD)
;~ Return 0
EndIf
;~ Sleep(30)
;~ Local $isCompleted = InetGetInfo($hDownload, $INET_DOWNLOADCOMPLETE)
;~ Local $isError = InetGetInfo($hDownload, $INET_DOWNLOADERROR)
;~ Sleep(30)
;~ If TimerDiff($hTimer) > 3000 And $isError Then
;~ ConsoleWrite("!PPH Fail" & @CRLF)
;~ InetClose($hDownload)
;~ $hDownload = 0
;~ Return 0
;~ EndIf
;~ Sleep(30)
Local $Show = 0
;~ If TimerDiff($hTimer) > 3000 And $isCompleted Then
If $hDownload > 0 Then
ConsoleWrite("+Downloaded..." & @CRLF)
Local $sPPHHtml = FileRead($sTempFile)
$aTitlesandUrls = _StringBetween($sPPHHtml, '"title">' & @LF, 'time>')
;~ _ArrayDisplay($aTitlesandUrls)
Local $aPPH[0][4]
Local $sTitle = ""
Local $sUrl = ""
Local $sID = ""
Local $sDate = ""
Local $iRet=0
Sleep(30)
For $i = 0 To UBound($aTitlesandUrls) - 1
$sTitle = _StringBetween($aTitlesandUrls[$i], '<a title="', '" class')
$sUrl = _StringBetween($aTitlesandUrls[$i], 'href="', '">')
$sDate = _GetDate($aTitlesandUrls[$i])
If IsArray($sTitle) And IsArray($sUrl) Then
$sID = _GetID($sUrl[0])
;~ _ArrayAdd($aPPH, $sDate & "|" & $sTitle[0] & "|" & $sUrl[0] & "|" & $sID)
$iRet = _BuildPopupsPPH($sID, $sDate, "PPH: " & $sTitle[0], $sUrl[0])
If $iRet Then $Show+=1
EndIf
Next
Sleep(30)
;~ If $Show > 0 Then ShowLatestJobs()
;~ _ArrayDisplay($aPPH)
FileDelete($sTempFile)
InetClose($hDownload)
$hDownload = 0
$hTimer = 0
Return $Show
EndIf
Sleep(30)
EndFunc ;==>_CheckPPH
-
By Jahar
Hi,
I am new to Autoit, Kindly guide me. I wanted to send a message with HTTP/GET to the URL https://ghsff.it/. How to do so?
-
By singh54
Hello All,
I am new to auto It and coding. Have only tried few automated logging for different websites. The login pages of the websites which I have worked on were having form name with input type as text and it seems straight forward to automate their login using "_IEFormElementSetValue".
I have got a url, it does not have any form in the source page. On further analyzing I found that It does call some login page separately as below.
function showLogin(arg) {
Global.pollingDialogDoc = null;
var fresh = jQuery.isValidString(arg) && "fresh" == arg ? !0 : !1, appFrame = $("#appFrame");
if ($("#modalFrame").show(), $("iframe").hide(), fresh || !appFrame.attr('src').match("html/login.html")) appFrame.attr('src', baseURL + 'html/login.html'),
appFrame.on('load', function() {
setTimeout(function() {
$("#modalFrame").hide(), appFrame.show();
}, 1);
}); else try {
window.frames.appFrame.updatePageFromIndex();
} catch (e) {}
}
I can simply use "send" and "mouse click" Method to automate the login but that doesn't seems very reliable. Is there any separate way to fill the user ID and password to the respective fields by having reference by frames or something.
Appreciate if any one can point me to correct document or help in any way...!
-
By HariKara
I have a script that seems to launch perfectly fine with IECreate, however, I want to launch the Browser and a specific URL with the RunAs command. I fairly new to AutoIT and wanted to know if someone can point me in the right direction.
Local $surl = "http://somewebsite.com/DODA/admin/job.aspx"
Local $oIE = _IECreate($sURL)
The above launches the website correctly with the correct URL, however, I have tried the below and this fails to load and browser?
#include <AutoItConstants.au3>
;========================
$oSleep = "200"
Local $surl = "http://somewebsite.com/DODA/admin/job.aspx"
Local $oIE = RunAs($args("username"), $args("domain"), $args("logonpassword"), "", "C:\Program Files (x86)\Internet Explorer\iexplore.exe http://somewebsite.com/DODA/admin/job.aspx")
_IELoadWait($oIE)
I get the following error back?
--> IE.au3 T3.0-2 Error from function _IELoadWait, $_IESTATUS_InvalidDataType
--> IE.au3 T3.0-2 Error from function _IEGetObjById, $_IESTATUS_InvalidDataType
--> IE.au3 T3.0-2 Error from function _IEGetObjById, $_IESTATUS_InvalidDataType
-