-Bird
This is a read-only snapshot of the ComputerCraft forums,
taken in April 2020.
HTTP API Bug
Started by Gumball, 04 June 2016 - 06:52 AMPosted 04 June 2016 - 08:52 AM
I have a website, and it has a domain. The domain is budgie.blue, but the HTTP API seems to not work with that. Instead I have to use its IP address. While this isn't a hassle, its a bit unsettling. Thanks!
-Bird
-Bird
Posted 04 June 2016 - 09:33 AM
Well. I dont know how you're connecting to your domain, but I am able to connect to your website with ease.
And here is an example of which methods, in my cases, work
I hope this helped you.
Also the settings for Computercraft should've been fixed, so i dont think the domain you're looking for is being blacklisted by CC. (If so, then change the whitelist to *)
(This is not a replicable bug, unless you prove otherwise with more examples/tests)
lua> x=http.get("http://budgie.blue/")
lua> x
table: somerandomID
lua> x.close()
I think you might have forgotten to add the http:// and then added www. (which in some cases appear to mess things up a bit, and hopefully in your case not work.)And here is an example of which methods, in my cases, work
I hope this helped you.
Also the settings for Computercraft should've been fixed, so i dont think the domain you're looking for is being blacklisted by CC. (If so, then change the whitelist to *)
(This is not a replicable bug, unless you prove otherwise with more examples/tests)
Edited on 04 June 2016 - 07:39 AM
Posted 04 June 2016 - 09:55 AM
Indeed, some more details as to how to reproduce the issue are required here. Where's your code, and what's the CC version?
Posted 04 June 2016 - 09:10 PM
Indeed, some more details as to how to reproduce the issue are required here. Where's your code, and what's the CC version?
I'm not sure of the version, I'm using CCEmuRedux. My code is
mail = http.post("http://budgie.blue/skyview/feedback.php","message=TestingFeedbackRelay")
if(mail) then
mail.close
return true
end
return false
What that does is send a POST request to my feedback relay on my webserver, which sends a message to a public email me and some others use for a collab i'm in. If I use the ip (45.34.14.48), then it works. With the actual domain itself, it doesn't send anything to my email, but it does return true.
Edited on 04 June 2016 - 07:10 PM
Posted 05 June 2016 - 06:37 AM
I'm not sure of the version, I'm using CCEmuRedux.
… so why were you posting this as a ComputerCraft bug?
Test it in-game, see if your posted message comes through, and if it still doesn't work try the variants Mikk809h gave you.
Posted 07 June 2016 - 01:11 PM
Perhaps your webhost is blocking non-browser User Agents? Cloudflare protected sites do this by default.
Posted 07 June 2016 - 08:06 PM
Perhaps your webhost is blocking non-browser User Agents? Cloudflare protected sites do this by default.
I doubt it. But it could be a problem with IIS Express? I have a Windows Server, and all the sites are stored in a wwwroot folder.
I'm not sure of the version, I'm using CCEmuRedux.
… so why were you posting this as a ComputerCraft bug?
Test it in-game, see if your posted message comes through, and if it still doesn't work try the variants Mikk809h gave you.
I've tried this many times in-game. Also CCEmuRedux uses a copy of ComputerCraft.jar, so I would bet it would be replicated in Minecraft.
Posted 07 June 2016 - 08:41 PM
Even if it uses the CC jar, it isn't CC and will work differently and have it's quirks. Test it in game so that you are sure that the problem ISN'T CCEmuRedux.
Posted 08 June 2016 - 07:20 PM
Perhaps your webhost is blocking non-browser User Agents? Cloudflare protected sites do this by default.
I doubt it. But it could be a problem with IIS Express? I have a Windows Server, and all the sites are stored in a wwwroot folder.I'm not sure of the version, I'm using CCEmuRedux.
… so why were you posting this as a ComputerCraft bug?
Test it in-game, see if your posted message comes through, and if it still doesn't work try the variants Mikk809h gave you.
I've tried this many times in-game. Also CCEmuRedux uses a copy of ComputerCraft.jar, so I would bet it would be replicated in Minecraft.
It's most likely cloudflare, I've had a problem similar to this and had to either remove cloudflare or allow it in the cloudflare settings.
Posted 14 June 2016 - 05:28 AM
Perhaps your webhost is blocking non-browser User Agents? Cloudflare protected sites do this by default.
I doubt it. But it could be a problem with IIS Express? I have a Windows Server, and all the sites are stored in a wwwroot folder.I'm not sure of the version, I'm using CCEmuRedux.
… so why were you posting this as a ComputerCraft bug?
Test it in-game, see if your posted message comes through, and if it still doesn't work try the variants Mikk809h gave you.
I've tried this many times in-game. Also CCEmuRedux uses a copy of ComputerCraft.jar, so I would bet it would be replicated in Minecraft.
It's most likely cloudflare, I've had a problem similar to this and had to either remove cloudflare or allow it in the cloudflare settings.
I don't use CloudFlare :P/>
Posted 14 June 2016 - 12:48 PM
if the server runs the CC client and connects to localhost does it have the same issue?