OpnenFL HTML5 how to detect http or https connection?


#1

is there any way to detect in Haxe / OpenFL protocol connection HTTP or HTTPS?


#2

It’s specific to html5, so do:

#if html5
import js.Browser
Browser.location.protocol
#end

#3

@loudo thanks it works

P.S.
sorry for late replay