E-junkie - We help you sell online
World Class Solution - Damon @ PayPal
Sell & promote your productsJoin affiliate programs offered by sellers Shop Community
community home . login . register . forums . submit content
 

E-junkie Ecommerce Forums » E-junkie Discussions

Tag Cloud for this topic:

php coding file help for e-junkie notifications



lemonbar
member
Posts: 293


can anyone supply their php code file to load an e-junkie notification into a mysql database.

maybe it is already on the site somehwere and if no tthen maybe e-junkie can add it for reference.

how do most handle errors. do they have an email sent to site admin?

do most of you have an email sent on successful ad as well?

thank you


#
POSTED ON: May 17, 2008 @ 14:00 GMT -7
MODIFIED ON: May 17, 2008 @ 14:32 GMT -7




lemonbar
member
Posts: 293


where is the entire list of codes/values we have access to?

does the notification list we get not always display all values? maybe due to being null?

what is the address field name? i only see city, state, zip listed on the site. is it 'address_street' ?


#
POSTED ON: May 17, 2008 @ 21:22 GMT -7
MODIFIED ON: May 18, 2008 @ 11:49 GMT -7




Tyson_N
E-Junkie Crew
Posts: 289


The values we can pass along to your own script (or to a 3rd-party service's URL) are listed here: http://www.e-junkie.com/ej/help.integration.php
(BTW, the street address variable would indeed be "address_street" -- looks like we missed that one in the documentation :^).

Notice at the very end of that page our "Passthru" instructions, which would just dump all the data we collect for each transaction to your URL, so you could capture that and sift thru everything to see what's useful or just grab what you need and ignore the rest.

Getting your own custom scripts to work is of course entirely up to you and your personal expertise with PHP or Perl or whatever you're scripting in; we cannot help develop or troubleshoot or bugfix your own scripting.


#
POSTED ON: May 19, 2008 @ 14:25 GMT -7




lemonbar
member
Posts: 293


I already finished my script after I posted the message.

However, I still think you guys would want to put a 'complete' php script there or a link to some robust examples (even better) or ones the manipulate the datebase.

It just makes it easier for more people to use your service.

Having a section on your site where code example are placed would be a cool thing as well.


#
POSTED ON: May 19, 2008 @ 14:44 GMT -7




lemonbar
member
Posts: 293


Also, there is a TON of items missing which leads to great confusion for new people trialing your service. I pointing this, and many many other things out right at the start when I joined...

Funny how people that pay me to improve their business listen but when its free advice it is disgarded. I have always laughed at that. I tell people all the time that they really do need to pay me to help them or it won't work lol.


#
POSTED ON: May 19, 2008 @ 14:51 GMT -7




dhacker
member
Posts: 31


A sample PHP script would be great. I got everything I needed but it was a big trial and error effort.


#
POSTED ON: May 19, 2008 @ 16:24 GMT -7




matthew239
member
Posts: 2


could you share the code you developed? I'm having the same issue right now. Thanks.


#
POSTED ON: July 21, 2008 @ 13:19 GMT -7




matthew239
member
Posts: 2


Sadly, nobody has chose to help me get started with the script to send transaction data to my url. The integration page is no help at all getting started. I don't want the whole script, all I need is a good start. Thanks to anyone who cares to help.


#
POSTED ON: August 7, 2008 @ 09:44 GMT -7




dhacker
member
Posts: 31


I wrote mine in ColdFusion, I'll post it tomorrow.


#
POSTED ON: August 7, 2008 @ 20:25 GMT -7




dhacker
member
Posts: 31


I set some defaults in case the parameters don't come in correctly

<cfparam name="payer_email" default="john@doe.com">
<cfparam name="txn_id" default="999999">
<cfparam name="first_name" default="firstname">
<cfparam name="last_name" default="lastname">
<cfparam name="mc_gross" default="0.00">
<cfparam name="address_city" default="novalue">
<cfparam name="address_state" default="novalue">
<cfparam name="address_zip" default="novalue">
<cfparam name="key" default="novalue">
<cfparam name="item_name1" default="novalue">
<cfparam name="item_number1" default="novalue">
<cfparam name="quantity1" default="novalue">
<cfparam name="mc_gross_1" default="mc_gross_1">

Based on our own configuration, we only really sell one product

<cfparam name="item_name2" default="novalue">
<cfparam name="item_number2" default="novalue">
<cfparam name="quantity2" default="novalue">
<cfparam name="mc_gross_2" default="mc_gross_2">

The parameters some in via a form

<cfset email='#Form.payer_email#'>
<cfset txn_id='#Form.txn_id#'>
<cfset first='#Form.first_name#'>
<cfset last='#Form.last_name#'>
<cfset mc_gross='#Form.mc_gross#'>
<cfset address_city='#Form.address_city#'>
<cfset address_state='#Form.address_state#'>
<cfset address_zip='#Form.address_zip#'>
<cfset key='#key#'>

<cfset item_name1='#Form.item_name1#'>
<cfset item_number1='#Form.item_number1#'>
<cfset quantity1='#Form.quantity1#'>
<cfset mc_gross_1='#Form.mc_gross_1#'>

<!-- only if it exists? -->
<CFIF IsDefined("FORM.quantity2")>
<cfset item_name2='#Form.item_name2#'>
<cfset item_number2='#Form.item_number2#'>
<cfset quantity2='#Form.quantity2#'>
<cfset mc_gross_2='#Form.mc_gross_2#'>
</CFIF>

<!-- Serial Numbers (Product Keys) are published with a Carraige Return/Line Feed, for simplicity I replace that with a "+" sign so I can stick them into one database field -->
<cfset key = Replace(key, Chr(13), "+", "ALL")>
<cfset key = Replace(key, Chr(10), "+", "ALL")>

Here is the real code

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>eJunkie Processing</title>
</head>
<body>

<!-- Here I'm creating an email as a backup mechanism -->
<CFMAIL TO="me@mydomain.com"
SERVER="mail.mydomain.com"
FROM="ejunkie@mydomain.com"
SUBJECT="eJunkie Purchase from #email#">
User Information
email: #payer_email#
txn_id: #txn_id#
First: #first#
Last: #last#
Payment: #mc_gross#
address_city=#address_city#
address_state=#address_state#
address_zip=#address_zip#

Serial Number
serialnumber=#key#

Item 1
item_name1=#item_name1#
item_number1=#item_number1#
quantity1=#quantity1#
mc_gross_1=#mc_gross_2#

Item 2
item_name2=#item_name2#
item_number2=#item_number2#
quantity2=#quantity2#
mc_gross_2=#mc_gross_2#

</CFMAIL>
<!-- now do the SQL Insert Statement -->
<cfquery name="qeJunkieInsert" datasource="mydatabase">
Insert into eJunkie (transactdate, txn_id, email, firstname, lastname, grossamount, city, state, zip, serialnumber)
values
(#CreateODBCDate(now())#, '#txn_id#', '#payer_email#', '#first#', '#last#', #mc_gross#, '#address_city#', '#address_state#', '#address_zip#', '#key#')
</cfquery>
Thanks
</body>
</html>

And that's it. Works for me, pretty simple.


#
POSTED ON: August 14, 2008 @ 09:46 GMT -7


You must be logged in to make a post. Please click here to login.

about | contact | resell | terms of service | privacy policy © 2008 19.5 Degrees. All rights reserved.
Designated trademarks and brands are the property of their respective owners.
Use of this Web site constitutes acceptance of the Terms of Service and Privacy Policy.
PayPal Certified Integration Google Checkout Certified Integrattion 30 Day Money Back Guarantee
 Share this page!