Digital Point Forums
Wester Union

Go Back   Digital Point Forums > Design & Development > Programming > PHP
Google Analytics
Log In to view
your analytics

Reply
 
Thread Tools
  #1  
Old Sep 15th 2006, 1:42 am
PinoyIto's Avatar
PinoyIto PinoyIto is offline
Astral Walker
 
Join Date: Dec 2004
Location: Philippines
Posts: 5,628
PinoyIto has a spectacular aura aboutPinoyIto has a spectacular aura about
Auto submit form using php

Hello, how can I auto submit a form using php? I know this is posible in javascript but I am not sure with PHP. If can, will you please post a sample how to do it...
Reply With Quote
  #2  
Old Sep 15th 2006, 3:02 am
vdd vdd is offline
Grunt
 
Join Date: Aug 2006
Posts: 31
vdd is on a distinguished road
It's possible and not too difficult. Use Curl library.
Reply With Quote
  #3  
Old Sep 15th 2006, 5:02 am
PinoyIto's Avatar
PinoyIto PinoyIto is offline
Astral Walker
 
Join Date: Dec 2004
Location: Philippines
Posts: 5,628
PinoyIto has a spectacular aura aboutPinoyIto has a spectacular aura about
Quote:
Originally Posted by vdd View Post
It's possible and not too difficult. Use Curl library.
Can you please show me some samples
Reply With Quote
  #4  
Old Sep 15th 2006, 6:31 am
vdd vdd is offline
Grunt
 
Join Date: Aug 2006
Posts: 31
vdd is on a distinguished road
POST example:
php Code:
<?
   $url = 'http://localhost/curl/1.php';
   $params = "keyword=123&zxczxc=333"; //you must know what you want to post
   $user_agent = "Mozilla/5.0 (compatible; MSIE 5.01; Windows NT 5.0)";
   $ch = curl_init();
   curl_setopt($ch, CURLOPT_POST,1);
   curl_setopt($ch, CURLOPT_POSTFIELDS,$params);
   curl_setopt($ch, CURLOPT_URL,$url);
   curl_setopt($ch, CURLOPT_USERAGENT, $user_agent);
   curl_setopt($ch, CURLOPT_RETURNTRANSFER,1);

   $result=curl_exec ($ch);
   curl_close ($ch);

   echo "Results: <br>".$result;
?>
1.php (just for test)
php Code:
<?
print_r($_POST);
?>
Reply With Quote
  #5  
Old Sep 16th 2006, 7:22 am
PinoyIto's Avatar
PinoyIto PinoyIto is offline
Astral Walker
 
Join Date: Dec 2004
Location: Philippines
Posts: 5,628
PinoyIto has a spectacular aura aboutPinoyIto has a spectacular aura about
Thank you very much mate....
Reply With Quote
  #6  
Old Jun 5th 2008, 4:49 am
chirayu chirayu is offline
Peon
 
Join Date: Jan 2008
Posts: 26
chirayu is on a distinguished road
Hi PinoyITO,

I am looking for auto form fill up javascript code. I am looking for that. If any one can provide me, kindly contact me at chirayu.sbc@gmail.com

Thanks a lot in advance.
Reply With Quote
Reply

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
php submit form to external site redbrad0 PHP 6 Aug 31st 2006 4:18 am
How to Stop form auto-submitters?? montux Site & Server Administration 8 May 19th 2006 8:49 pm
submit form in frame2 after submitting form in frame1 Oreamnos JavaScript 3 Mar 27th 2006 7:24 am
PHP Form Script - To Submit Articles dcristo PHP 4 Jan 3rd 2006 6:43 am
Just received a strange auto email form G Ch-Nauman AdSense 10 Dec 6th 2005 11:06 pm


All times are GMT -8. The time now is 11:55 am.