I've set up alertpay, using there guide, and there example script with a few mods... The page with the payment button. <form method="post" action="https://www.alertpay.com/PayProcess.aspx" > <input type="hidden" name="ap_purchasetype" value="item"/> <input type="hidden" name="ap_merchant" value="alertpay@xxx.com"/> <input type="hidden" name="ap_itemname" value="Testing"/> <input type="hidden" name="ap_description" value="Testing"/> <input type="hidden" name="ap_currency" value="USD"/> <input type="hidden" name="ap_returnurl" value="http://www.xxx.com/thankyou.php"/> <input type="hidden" name="ap_itemcode" value="<? echo $_SESSION["username"]; ?>"/> <input type="hidden" name="ap_quantity" value="1"/> <input type="hidden" name="ap_amount" value="10"/> <input type="image" name="ap_image" src="https://www.alertpay.com/Images/BuyNow/big_pay_01.gif"/> </form> PHP: The ipn.php file, which is where the data should be getting sent too <? require("ipndata.php"); // imports security code $ap_sec_code = $_POST['ap_securitycode']; if (strcmp($security_code, $ap_sec_code) == 0){ if($_POST["ap_itemname"] == "Testing") { $username=$_POST["ap_itemcode"]; $query=mysql_query("INSERT INTO upgraded VALUES (NULL, '{$_SESSION["username"]}', curdate())"); } } ?> PHP: And then just the thankyou.php has a thanks message. But when i run a test payment (in test mode) the upgraded table still remain blank... any help or ideas?
First check this by using mail() instead of mysql_query() function if it works then double check your query.