Send failed since rewinding of the data stream failed

I’m using WWW class to sent a WWWForm to an asp.net server.
it used to work in unity 5.3.x but since I migrated to 5.6.3f1, it is not working and sending ‘Send failed since rewinding of the data stream failed’ message.
I tried doing it with the UnityWebRequest but it couldn’t send the data in the form and I would get null values in the server side. here is my code:

    public static IEnumerator PostToServer(string url, WWWForm data)
    {
        WWW www = new WWW(url, data);

        yield return www;

        if (www.error != null)
        {
            Debug.Log(www.error);
        }
        else
        {
            Debug.Log(www.text);
        }
    }

I tested the exact same code in a new empty project and it worked as it should have. what is the problem?
I am able to get data from server with WWW but post is not working.
Also my computer got a virus and started eating the files in my c drive so I reinstalled my windows.but my project was not in that drive, could it be that something is corrupted? if so, how should i fix it?

For anyone getting this error in the future, your server might be configured to redirect some kinds of requests.
In my case I was requesting GET with an address like:“http://www.website.com/”. AFAIK this should have worked for the POST requests as well, but it didn’t, and after searching around I found this address to be working:“http://website.com/”.
Maybe this is an obvious thing and I just didn’t know about it. But anyway, this fixed it for me.