Hello there. Im trying to send data to a php script with WWW and WWWForm. It was working before but at some point it stopped. Suddenly i keep getting a “necessary data rewind wasn’t possible” errror. As soon as I comment out all the "AddField"s or not include the form in the WWW call it works perfectly.
Any ideas?
This is the code of my jscript function
function Start() {
var highscore_url = "http://example.com/script.php";
var form = new WWWForm();
form.AddField( "var1", "value1" );
form.AddField( "var2", "value2");
var www = new WWW( highscore_url, form );
// wait for request to complete
yield www;
// and check for errors
if (www.error == null)
{
// request completed!
} else {
// something wrong!
Debug.Log("WWW Error: "+ www.error);
}
Hi fxjeane / future data rewind problem-hitters,
We just ran into and solved this one – our PHP script was redirecting ( header(“Location:http://…”) ). Removing this redirect fixed the problem for us.
I am using this without subdomain means I am using http://128.0.0.255/
i am sharing wrong ip address but i am using like this. so now what solution works for me because this issue occur in some machine or not all the time.