fabmsg Posted December 9, 2014 Share Posted December 9, 2014 Hi! I'm trying to make an button that when it's pressed sends an http post to my home server. But my home server is runing on port 84 and i think that i'm not being able to send the post correctly because of this port. any help? my code now is this: $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "http://homeserver.net:84/?device=35"); curl_setopt($ch, CURLOPT_HEADER, 0); curl_exec($ch); curl_close($ch); The way I have the URL is correct? thanks! Quote Link to comment Share on other sites More sharing options...
WinstonLA Posted December 9, 2014 Share Posted December 9, 2014 (edited) Try to add CURLOPT_PORT curl_setopt($ch, CURLOPT_PORT, 84); Edited December 9, 2014 by WinstonLA Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.