I recently attempted to learn how to use TCP Objects, but apparently either I'm doing something wrong, or you can't use TCPs with Hostinger.
Here's what I've done:
new TCPObject(TCPTest);
function TCPTest::onLine(%this, %line)
{
echo("LINE:" SPC %line);
}
function TCPTest::onConnected(%this)
{
%this.send("GET /AdminRules.html /HTTP1.0\nHost: cruxeis.url.ph\nUser-Agent: Torque\n\r\n\r\n");
}
TCPTest.connect("cruxeis.url.ph:80");
And this is the error it gives me:
And I'm pretty sure the file hasn't moved..
Anyone know how to fix this? Am I forgetting an \r or something?