e-gold is my favorite online payment method

and i'll share how to integrate it with your script.
it is documented at
This document describes how to interface a web-based "shopping cart" system to the e-gold payment system
here i made simpler one, and you just need to modify it to suit your requirement.
first, you must have a form to start the payment
HTML Code:
<FORM ACTION="https://www.e-gold.com/sci_asp/payments.asp" METHOD="POST">
<INPUT TYPE="HIDDEN" NAME="PAYEE_NAME" VALUE="YOUR EGOLD NAME">
<INPUT TYPE="HIDDEN" NAME="PAYMENT_ID" VALUE="SEE NOTES 1">
<INPUT TYPE="HIDDEN" NAME="PAYEE_ACCOUNT" VALUE="YOUR EGOLD NUMBER">
<INPUT TYPE="HIDDEN" NAME="PAYMENT_URL_METHOD" VALUE="POST">
<INPUT TYPE="HIDDEN" NAME="PAYMENT_URL" VALUE="SEE NOTES 2">
<INPUT TYPE="HIDDEN" NAME="CUSTOMERID" VALUE="0">
<INPUT TYPE="HIDDEN" NAME="BAGGAGE_FIELDS" VALUE="CUSTOMERID">
<INPUT TYPE="HIDDEN" NAME="NOPAYMENT_URL_METHOD" VALUE="POST">
<INPUT TYPE="HIDDEN" NAME="NOPAYMENT_URL" VALUE="SEE NOTES 3">
<INPUT TYPE="HIDDEN" NAME="STATUS_URL" VALUE="SEE NOTES 4">
<INPUT TYPE="HIDDEN" NAME="SUGGESTED_MEMO" VALUE="SEE NOTES 5">
<INPUT TYPE="HIDDEN" NAME="PAYMENT_METAL_ID" VALUE=1>
<INPUT TYPE="HIDDEN" NAME="PAYMENT_UNITS" VALUE=1>
<INPUT TYPE="HIDDEN" NAME="FORCED_PAYER_ACCOUNT" VALUE="SEE NOTES 6">
Amount :
<input name="PAYMENT_AMOUNT" type="text" value="1" size="5" /> USD
<br>
<INPUT TYPE="submit" NAME="PAYMENT_METHOD" VALUE="Pay">
</FORM>
Notes 1 : Payment ID : here you can put an ID such as transaction ID, user ID, or something that you can connect with your database.
Notes 2 : this link will called after user done payment
Notes 3 : this link will called when user cancel to pay
Notes 4 : this link will called by egold, egold will send the payment information to this link.
Notes 5 : memo that you suggest
Notes 6 : if you already know your customer's e-gold number, you can put here. if you didn't put any number here, customer will entry their egold number.
ok, now for notes 4,
for example, you have domain
www.domain.com ; place
http://www.domain.com/egpay.php at notes 4.
egpay.php will retrieve information directly from egold.... you can do some query into your DB at this file... or send a report email to you.
here is the content of egpay.php
PHP Code:
<?
//your alternate password
$altpass="your egold alternate passphrase";
//=======================
$payee_account=$_POST['PAYEE_ACCOUNT'];
$payment_id=$_POST['PAYMENT_ID'];
$payment_amount=$_POST['PAYMENT_AMOUNT'];
$payment_units=$_POST['PAYMENT_UNITS'];
$payment_metal_id=$_POST['PAYMENT_METAL_ID'];
$payment_batch_num=$_POST['PAYMENT_BATCH_NUM'];
$payer_account=$_POST['PAYER_ACCOUNT'];
$actual_payment_ounces=$_POST['ACTUAL_PAYMENT_OUNCES'];
$usd_per_ounce=$_POST['USD_PER_OUNCE'];
$feeweight=$_POST['FEEWEIGHT'];
$v2_hash=$_POST['V2_HASH'];
$timestampgmt=$_POST['TIMESTAMPGMT'];
$alpp=strtoupper(md5($altpass));
$v2hash="$payment_id:$payee_account:$payment_amount:$payment_units:$payment_metal_id:$payment_batch_num:$payer_account:$alpp:$actual_payment_ounces:$usd_per_ounce:$feeweight:$timestampgmt";
$v2hashgen=strtoupper(md5($v2hash));
if ($v2_hash==$v2hashgen )
{
$eg_payment_id=$payment_id;
$eg_amount=$payment_amount;
$eg_payer=$payer_account;
$eg_batch=$payment_batch_num;
//do action here
//put query or mail function here
//notes 7
}
?>
notes 7 : you can put some query here or make a mail function that will send you an email. i've put 4 variable that you can use... feel free to modify it to suit your case.
any bug/suggestion/error, plase post here.
i've using it since long time ago, but in this post, i made it simpler.
please do a testing before you use it. (spend 0,01$ egold from your accoun into your accoun to test it

)
enjoy !