Answer the question
In order to leave comments, you need to log in
Reddit API and cURL account creation?
I'm working on an app that allows users to create an account on Reddit (and more), this is my code.
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,"https://www.reddit.com/post/reg");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS,
"user=valueuser1&passwd=value2password&passwd2=value2password");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$server_output = curl_exec ($ch);
curl_close ($ch);
if ($server_output == "OK") {
echo "true";} else { echo "false"; }
false
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question