我想将$_GET
变量转换为$_POST
paypal以隐藏返回网址
<?
//i want Convert $_GET variables to $_POST paypal to hide return url
$return = 'http://my site. com/tks.php?id=150';
$mypost='cmd=_cart¤cy_code=USD&business=email@gmail.com&tax_cart=0.00&handling_cart=0.00&charset=utf-8
&item_name_1=IDM Download Manager(4)&quantity_1=1&amount_1=5.00&item_number_1=1&option_index_0=0&return='.$return;
// this $mypost will be post to $posted url
// i don't want this method $posturl = 'https://www.paypal.com/cgi-bin/webscr?$mypost';
$posturl = 'https://www.paypal.com/cgi-bin/webscr?';
header("Location: $posturl");
?>
答案 0 :(得分:0)
在客户端使用jQuery
并将$return
编码为JSON
,并使用POST
方法类型将其发布到服务器。