Custom headers HTTP protected site
Dave Cragg
dave.cragg at lacscentre.co.uk
Sun Oct 11 04:40:28 EDT 2009
On 11 Oct 2009, at 04:49, Jim Ault wrote:
> This worked for my case
>
> get "http://loginn:passwordd@www.baseballhq.com/"
> get it & "members/tools/"
> get it & "projections/proj.php"
> put url it into allPitchersBlock
>
> put libURLLastHTTPHeaders() into headersToAnalyze
> --one of the headers is Authorization: Basic
> cm90b3Bhc3MyOjUzcHJpbmNlNDY=
>
> filter headersToAnalyze with "*Author*"
> put headersToAnalyze into msg
You can create the authorization string yourself assuming you know the
name and password . The following should do it:
set the httpHeaders to "Authorization: Basic " & basicAuthString
("myName","myPassword")
function basicAuthString pName, pPass
return base64Encode(pName & ":" & pPass)
end basicAuthString
This is for the Basic authentication scheme only.
Dave
More information about the use-livecode
mailing list