curl post forms

Started on the old forum in May 2011 · view the original in the archive · old links redirect here

2 replies · 436 views · started 15 years ago · 1 min read

2 participants
atef Developer · 224 posts #1

hey guys im trying to post forms without show the page after post it my code

function sendsms($number, $message)
{
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,"http://test.com");
curl_setopt ($ch, CURLOPT_HEADER, 0); 
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS,"number={$number}&msg={$message}"); 
$result = curl_exec($ch); 
curl_close($ch);
}
i0nutzxp Developer · 150 posts #2

curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);

<?php unlink('World/Europe/Romania.country'); ?>

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close