乱讲的吧!fopen 是用来打开文件的

解决方案 »

  1.   

    你打开网址不是一样吗?
    带上参数不就可以了吗?
    那用fputs()吧。用fsockopen连接上,弄一个post的http头,用fputs发送过去就可以了。
    真是没见识。
      

  2.   

    用javascript让表单自动提交
      

  3.   

    要将a.php提交到支付平台:
    header("Location: Url地址?需要的参数");
      

  4.   

    也可以修改模板上html的<form method="POST" ···>
      

  5.   

    lisoon((水翡草芥--突然想去扫街))好像没理解我的意思,请认真看一下问题。uuq(杜牧)讲的我也想过,但我想知道有没有其它办法
    xxluan(乱乱)的header那不就成GET请求了吗?
    <form method="POST" ···>这种不还是要用户点击吗?看来只好让用户再点击一次喽~
      

  6.   

    lisoon((水翡草芥--突然想去扫街))好像没理解我的意思,请认真看一下问题。
    ------------
    我看是你没理解人家的意思!问题已经说的很清楚了,建议去看一下HTTP协议
      

  7.   

    给你代码吧,这个是paypal的接口代码。// read the post from PayPal system and add 'cmd'
    $req = 'cmd=_notify-validate';foreach ($_POST as $key => $value) {
    $value = urlencode(stripslashes($value));
    $req .= "&$key=$value";
    }// post back to PayPal system to validate
    $header .= "POST /cgi-bin/webscr HTTP/1.0\r\n";
    $header .= "Content-Type: application/x-www-form-urlencoded\r\n";
    $header .= "Content-Length: " . strlen($req) . "\r\n\r\n";
    $fp = fsockopen ('www.paypal.com', 80, $errno, $errstr, 30);// assign posted variables to local variables
    $item_name = $_POST['item_name'];
    $item_number = $_POST['item_number'];
    $payment_status = $_POST['payment_status'];
    $payment_amount = $_POST['mc_gross'];
    $payment_currency = $_POST['mc_currency'];
    $txn_id = $_POST['txn_id'];
    $receiver_email = $_POST['receiver_email'];
    $payer_email = $_POST['payer_email'];if (!$fp) {
    // HTTP ERROR
    } else {
    fputs ($fp, $header . $req);
    while (!feof($fp)) {
    $res = fgets ($fp, 1024);
    if (strcmp ($res, "VERIFIED") == 0) {
    // check the payment_status is Completed
    // check that txn_id has not been previously processed
    // check that receiver_email is your Primary PayPal email
    // check that payment_amount/payment_currency are correct
    // process payment
    }
    else if (strcmp ($res, "INVALID") == 0) {
    // log for manual investigation
    }
    }
    fclose ($fp);
    }
    ?>
      

  8.   

    我换一种问法!!!http://community.csdn.net/Expert/topic/4559/4559677.xml?temp=.1897547
      

  9.   

    真无聊……-------------------------
    a.php<form method=post action=b.php>
    <input name=aaa><br>
    <input name=bbb><br>
    <input name=ccc><br>
    <input type=submit>
    </form>---b.php
    <?//你在这里处理吧?>
    <form name=test method=post action=c.php>
    <input name=aaa value='<?=$aaa?>'><br>
    <input name=bbb value='<?=$bbb?>'><br>
    <input name=ccc value='<?=$ccc?>'><br>
    <input type=submit>
    </form>
    <script>
    test.submit();
    </script>---
    c.php<?
    print_r($_POST);
    ?>