The code below gives 403 error. but my request works for localhost:8080 but doesn't for the url mentioned in the code. the url and the folder in the header is completely correct, but i don't understand where the problem lies

```
import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.net.InetAddress;
import java.net.Socket;
import java.net.URL;
import java.net.URLEncoder;

public class Main 
{
    public static void main(String[] args)
    {
        try
        {
            String data = URLEncoder.encode("name","UTF-8")+"="+URLEncoder.encode("parsa1234","UTF-8");
            Socket s = new Socket("ramsari.com",80);
            BufferedReader reader = new BufferedReader(new InputStreamReader(s.getInputStream()));
            BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(s.getOutputStream(),"UTF-8"));
            writer.write("POST /help/index.php HTTP/1.0\r\n");
            writer.write("content-length:"+data.length()+"\r\n");
            writer.write("Content-Type:application/x-www-form-urlencoded\r\n");
            writer.write("\r\n");
            writer.write(data);
            writer.flush();
            String c = "";
            while((c = reader.readLine()) != null)
            {
                System.out.println(c);
            }
            writer.close();
            reader.close();

        }
        catch(IOException e)
        {
            e.printStackTrace();
        }
    }
}

```

this is my code on ramsari.com/help/index.php

```
<?php
if(isset($_POST['name']))
{
    echo $_POST['name'];
}
else
{
    echo "error";
}

```

and here is the response from the url

```
HTTP/1.1 403 Forbidden
Server: nginx/1.12.1 (Ubuntu)
Date: Mon, 26 Mar 2018 15:08:38 GMT
Content-Type: text/html
Content-Length: 162
Connection: close

<html>
<head><title>403 Forbidden</title></head>
<body bgcolor="white">
<center><h1>403 Forbidden</h1></center>
<hr><center>nginx</center>
</body>
</html>

```