Sign in to follow this  
Followers 0
darzanmihai

http post to .php file - need help

7 posts in this topic

I whant to make an application to send data to a .php file with POST command but I do not know how.

I have made an atempt to make the .php file:

<?php

$mesaj = "Nume: ".@$_POST["data"]."<br>";

$fp = fopen("EmailData.txt", "a");

fwrite($fp, $mesaj."||");

fclose($fp);

echo "&ok=ok&";

?>

,but I do not know how to sent data with autoit to the @$_POST from the php file...

I have tryed:

#include <HTTP.au3>

$resp = _HTTPPost("www.digitalenergy.ro", "/AutoTeamViewer/send.php", 20, "merge")

MsgBox(0,@error,$resp)

HTTP.au3 from : HTTP.au3

but it does not work...I get @error=2, but anyway, I am not sure this is the way to do it.


I do not like stupid and idiot people that write idiot things...If you are one, do not write.

Share this post


Link to post
Share on other sites



Any Ideea..someone?


I do not like stupid and idiot people that write idiot things...If you are one, do not write.

Share this post


Link to post
Share on other sites

Use GET method. Much simpler.

do you have am example?


I do not like stupid and idiot people that write idiot things...If you are one, do not write.

Share this post


Link to post
Share on other sites

PHP File:

<?php

$mesaj = "Nume: ".@$_REQUEST["data"]."<br>";

$fp = fopen("EmailData.txt", "a");
fwrite($fp, $mesaj."||");
fclose($fp);


echo "&ok=ok&";

?>

AutoIt:

InetGet("www.digitalenergy.ro/AutoTeamViewer/send.php?data=lolhacks")

See ?

Share this post


Link to post
Share on other sites

PHP File:

<?php

$mesaj = "Nume: ".@$_REQUEST["data"]."<br>";

$fp = fopen("EmailData.txt", "a");
fwrite($fp, $mesaj."||");
fclose($fp);


echo "&ok=ok&";

?>

AutoIt:

InetGet("www.digitalenergy.ro/AutoTeamViewer/send.php?data=lolhacks")

See ?

Thx for reply. The php code worked perfectly when executed from the browser but the autoit code doesn't work and return 0. Is there something else I could try?

I do not like stupid and idiot people that write idiot things...If you are one, do not write.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0