Here's my request function
function ConnectToHostAndSendRequest(sPage$ , sData$)
debugOn = 1
internetOK = GetInternetState()
WriteDebug(debugOn , "ConnectToHostAndSendRequest(sPage$ = " + sPage$ + " , sData$" + sData$ + ") = internetOK = " + str(internetOK) , 0 , 1)
if internetOK = 1
if con.ID = 0
HandleHTTPConnection(0) // creates new connection if needed
endif
if con.ID > 0 and con.page$ = ""
if iSECURE_ON = 0
SetHTTPHost(con.ID, sHOST , iHTTPS_ON)
elseif iSECURE_ON = 1
SetHTTPHost(con.ID, sHOST , iHTTPS_ON , sHOST_USER , sHOST_PW)
endif
SendHTTPRequestASync(con.ID , sPage$ , sData$)
con.page$ = sPage$
con.post$ = sData$
con.reqTime = GetMilliseconds()
con.reqDelay = con.reqTime
endif
endif
WriteDebug(debugOn , " con.ID = " + str(con.ID) + " con.page$ = " + con.page$ , 0 , 1)
WriteDebug(debugOn , " con.reqTime = " + str(con.reqTime) , 0 , 1)
WriteDebug(debugOn , "" , 0 , 1)
endfunction
It's really quite straight forward and I'm very perplexed as to how you have it working and it would not work at all on the simulator or on my friend's iPhone until I removed the password protection on my server's directory AND switched over to SetHTTPHost(con.ID, sHOST , iHTTPS_ON)
Maybe it is related to iOS 7? I also really didn't like how Xcode's log window was showing the user name and password combo. Makes me feel like someone could snag the APP file and plug their device in to a computer with XCode and it will show them my protected directory password. But I'm more concerned that it just doesn't work.