Jump to content

Reading information from a website


 Share

Recommended Posts

Hi out there !

i am trying to read the version number of the actual chrome stable release from a website and keep failing due to less html knowledge. Maybe someone can help me please.

The website is  https://chromiumdash.appspot.com/releases?platform=Windows

I tried something like this in several versions. But without any solution....

    Local $sURL = "https://chromiumdash.appspot.com/releases?platform=Windows"
    Local $oHTTP = ObjCreate("winhttp.winhttprequest.5.1")
    $oHTTP.Open("GET", $sURL)
    $oHTTP.Send()
    $sHTMLBIN = $oHTTP.Responsetext
    Local $sHTML = BinaryToString($sHTMLBIN)

 

Alternately the version is also visible on this site: https://chromeenterprise.google/intl/de_de/browser/download/#windows-tab

But i didn't get it from there either.

Any solutions welcome 🙂

 

Link to comment
Share on other sites

2 hours ago, agivx3 said:

Any solutions welcome

This should do the job

#include <String.au3>
Local $sNETSource = BinaryToString(InetRead("https://chromiumdash.appspot.com/fetch_releases?channel=Stable&platform=Windows&num=1", 2))
Local $aLatestStableVersion = _StringBetween($sNETSource, ',"version":"', '"}]')
ConsoleWrite($aLatestStableVersion[0] & @CRLF)

 

Musashi-C64.png

"In the beginning the Universe was created. This has made a lot of people very angry and been widely regarded as a bad move."

Link to comment
Share on other sites

#include <array.au3>
 Local $aCromiumVersions[][] = _
[['Windows:',BinaryToString(InetRead("https://omahaproxy.appspot.com/win"))], _
['Linux:',BinaryToString(InetRead("https://omahaproxy.appspot.com/linux"))], _
['Mac:',BinaryToString(InetRead("https://omahaproxy.appspot.com/mac"))]]

_ArrayDisplay($aCromiumVersions,'stable version')

source: https://stackoverflow.com/questions/35114642/get-latest-release-version-number-for-chrome-browser

 

image.jpeg.9f1a974c98e9f77d824b358729b089b0.jpeg Chimp

small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt....

Link to comment
Share on other sites

if you need some more info on the chromium versions... 

#include <array.au3>
_ArrayDisplay(_StringSplit2D(StringStripWS(BinaryToString(InetRead("https://omahaproxy.appspot.com/all", 1)), 2), @LF, ','))

Func _StringSplit2D($var, $sRowSeparator = @LF, $sColumnSeparator = ',')
    Local $aRows = StringSplit($var, $sRowSeparator), $aColumns, $aResult[$aRows[0]][0]
    For $iRow = 1 To $aRows[0]
        $aColumns = StringSplit($aRows[$iRow], $sColumnSeparator)
        If $aColumns[0] > UBound($aResult, 2) Then
            ReDim $aResult[$aRows[0]][$aColumns[0]]
        EndIf
        For $iColumn = 1 To $aColumns[0]
            $aResult[$iRow - 1][$iColumn - 1] = $aColumns[$iColumn]
        Next
    Next
    Return $aResult
EndFunc   ;==>_StringSplit2D

 

 

image.jpeg.9f1a974c98e9f77d824b358729b089b0.jpeg Chimp

small minds discuss people average minds discuss events great minds discuss ideas.... and use AutoIt....

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...