objective c - IOS Create button to hit a URL without opening in Safari -


i have found code open link upon pressing button, don't want open link, send command web controller without exiting app.

[[uiapplication sharedapplication] openurl:[nsurl urlwithstring:@"192.168.0.100/outlet?5=on"]] 

is there way modify don't leave app, still send command controller?

eventually want send on command, wait 20 seconds, send off command.


Popular posts from this blog

node.js - How do I prevent MongoDB replica set from querying the primary? -

c# - Randomly pick a specific int from a 2D Array -

php - Angularjs http.delete is not working after deploying project on server -