strangename
Pioneers-
Posts
37 -
Joined
-
Last visited
Profile Information
-
Real Name
John McEvansoneya
Recent Profile Visitors
3,319 profile views
strangename's Achievements
-
Reference the above: Sorry, should have mentioned that the contribution version I am using is v2.0
-
I have installed the contribution which will fit my needs perfectly and am grateful , however I have slight problem which I can't work out. I can access products perfectly if I select them from a "featured product" listing on the front page but if I try to view a product through my menu system I get the following error: I have checked and double checked the code and I have made the necessary changes. Any help in directing me in the right direction would be most gratefully received. I am using OsC 2.2-RC2a and MySQL5.0. If I haven't given enough info please let me know. Thanks in advance John
-
[CONTRIBUTION] PDF Customer Invoice
strangename replied to chris23's topic in General Add-Ons Support
Hi Chris, Thanks for the response and the kick in the right direction. All sorted out. I should have figured it out myself. Sorry for being so dim!! Thanks again for your time for producing this great contribution. John -
I hope someone can help me out with this little problem. I have installed this contribution a number of times in a number of ways including installing to a brand new shop. I am using the rc2.2a version of OsCommerce. Everything appears to works fine when you view the site in Firefox however in Internet Explorer v7 the product_info.php page displays with the right hand column dropping below the "Reviews" button. Any help will be most gratefully accepted as I think that this contribution is a "must" for good SEO practice.
-
[CONTRIBUTION] PDF Customer Invoice
strangename replied to chris23's topic in General Add-Ons Support
Hi Chris, Thanks for creating this mod which I think makes things look far more pleasing. Wonder if you could point me in the right direction. I loaded the mod on to an unaltered 2.2RC2a version and all seems to go well except I keep getting the following show up on the invoice output. Order number: 1 Date of Order: 04/18/2008 Payment Method: Cash on Delivery PDF_INV_CUSTOMER_REF2 I maybe acting like a muppet but I just can't find the problem. Any thoughts or help would be most appreciated. Thanks in advance John -
If you are in the UK then I would suggest Protx. They have fixed fee and the support on this site as well as their customer support is excellant.
-
I keep forgetting I can't edit these posts. ***Update*** What I need to know is where is the best place to place an "echo $data" statement?
-
I am in a bit of a fix and am looking for any help. I am trying to install Realex on to a site and am having a problem. The payment process goes fine until checkout_confirmation.php where only part of the screen is produced...the bottom part with the button to confirm the order is correct does not show (it works fine with other modules). I have spoken to Realex who have said to send them what data I am sending so they can see if it is hitting their server. What is the best way to produce an output that I can send to them? I have included the Realex module (they wrote it but can't help!!) below for reference. Thanks for any help in advance, no matter how small - John <?php /* $ */ class realex { var $code, $title, $description, $enabled; var $oid; // class constructor function realex() { global $order; $this->code = 'realex'; $this->title = MODULE_PAYMENT_REALEX_TEXT_TITLE; $this->description = MODULE_PAYMENT_REALEX_TEXT_DESCRIPTION; $this->sort_order = MODULE_PAYMENT_REALEX_SORT_ORDER; $this->enabled = ((MODULE_PAYMENT_REALEX_STATUS == 'True') ? true : false); if ((int)MODULE_PAYMENT_REALEX_ORDER_STATUS_ID > 0) { $this->order_status = MODULE_PAYMENT_REALEX_ORDER_STATUS_ID; } if (is_object($order)) $this->update_status(); $this->form_action_url = 'https://epage.payandshop.com/epage.cgi'; } // class methods function update_status() { global $order; if ( ($this->enabled == true) && ((int)MODULE_PAYMENT_REALEX_ZONE > 0) ) { $check_flag = false; $check_query = tep_db_query("select zone_id from " . TABLE_ZONES_TO_GEO_ZONES . " where geo_zone_id = '" . MODULE_PAYMENT_REALEX_ZONE . "' and zone_country_id = '" . $order->billing['country']['id'] . "' order by zone_id"); while ($check = tep_db_fetch_array($check_query)) { if ($check['zone_id'] < 1) { $check_flag = true; break; } elseif ($check['zone_id'] == $order->billing['zone_id']) { $check_flag = true; break; } } if ($check_flag == false) { $this->enabled = false; } } } function javascript_validation() { return false; } function selection() { return array('id' => $this->code, 'module' => $this->title); } function pre_confirmation_check() { return false; } function confirmation() { return false; } function process_button() { global $osC_Session, $order, $currencies; if (MODULE_PAYMENT_REALEX_CURRENCY == 'Selected Currency') { $my_currency = $osC_Session->value('currency'); } else { $my_currency = substr(MODULE_PAYMENT_REALEX_CURRENCY, 5); } if (!in_array($my_currency, array('CHF', 'EUR', 'GBP', 'JPY', 'USD', 'SEK', 'HKD'))) { $my_currency = 'USD'; } //Replace these with the values you receive from Realex Payments $merchantid = MODULE_PAYMENT_REALEX_ID; $secret = MODULE_PAYMENT_REALEX_SECRET; //The code below is used to create the timestamp format required by Realex Payments $timestamp = strftime("%Y%m%d%H%M%S"); mt_srand((double)microtime()*1000000); /* orderid: Timestamp - randvalue */ $orderid = $timestamp . "-" . mt_rand(1, 999); $curr = $my_currency; $amount = number_format($order->info['total'] * $currencies->get_value($my_currency), $currencies->get_decimal_places($my_currency)) * 100; /*md5 crypt*/ $tmp = "$timestamp.$merchantid.$orderid.$amount.$curr"; $md5hash = md5($tmp); $tmp = "$md5hash.$secret"; $md5hash = md5($tmp); $process_button_string = tep_draw_hidden_field('MERCHANT_ID', MODULE_PAYMENT_REALEX_ID) . tep_draw_hidden_field('osCsid', session_id()) . tep_draw_hidden_field('ORDER_ID', $orderid) . tep_draw_hidden_field('AMOUNT', $amount) . tep_draw_hidden_field('CURRENCY', $curr) . tep_draw_hidden_field('TIMESTAMP', $timestamp) . tep_draw_hidden_field('AUTO_SETTLE_FLAG', 1) . tep_draw_hidden_field('RETURN_TSS', 1) . tep_draw_hidden_field('BILLING_CODE', $order->billing['postcode']) . tep_draw_hidden_field('BILLING_CO', $order->billing['country']['iso_code_2']) . tep_draw_hidden_field('MD5HASH', $md5hash). tep_draw_hidden_field('COMMENT', urldecode($order->billing['firstname']) . ' ' . urldecode($order->billing['lastname']) . (strlen($order->billing['company'])>0?' ' . urldecode($order->billing['company']):'') ) . tep_draw_hidden_field('PROD_ID', STORE_NAME); return $process_button_string; } function before_process() { global $HTTP_POST_VARS; $error = false; $merchantid = MODULE_PAYMENT_REALEX_ID; $secret = MODULE_PAYMENT_REALEX_SECRET; $timestamp = $HTTP_POST_VARS['TIMESTAMP']; $result = $HTTP_POST_VARS['RESULT']; $orderid = $HTTP_POST_VARS['ORDER_ID']; $message = $HTTP_POST_VARS['MESSAGE']; $authcode = $HTTP_POST_VARS['AUTHCODE']; $pasref = $HTTP_POST_VARS['PASREF']; $md5hash_post = $HTTP_POST_VARS['MD5HASH']; $tmp = "$timestamp.$merchantid.$orderid.$result.$message.$pasref.$authcode"; $md5hash_new = md5($tmp); $tmp = "$md5hash_new.$secret"; $md5hash_new = md5($tmp); //Check to see if hashes match or not if ($md5hash_new != $md5hash_post) { $payment_error_return = 'payment_error=' . $this->code . '&error=' . TEXT_REALEX_HASH_ERROR; tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, $payment_error_return, 'SSL', true, false)); } if ($result !='00') { $payment_error_return = 'payment_error=' . $this->code . '&error=' . urlencode($message); tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, $payment_error_return, 'SSL', true, false)); } return false; } function after_process() { return false; } function get_error() { if (PHP_VERSION < 4.1) { global $_GET; } $error = array('title' => REALEX_ERROR_TITLE, 'error' => ((isset($_GET['error'])) ? stripslashes(urldecode($_GET['error'])) : IPAYMENT_ERROR_MESSAGE)); return $error; } function output_error() { return false; } function check() { if (!isset($this->_check)) { $check_query = tep_db_query("select configuration_value from " . TABLE_CONFIGURATION . " where configuration_key = 'MODULE_PAYMENT_REALEX_STATUS'"); $this->_check = tep_db_num_rows($check_query); } return $this->_check; } function install() { tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Enable Realex Module', 'MODULE_PAYMENT_REALEX_STATUS', 'True', 'Do you want to accept Realex payments?', '6', '3', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Merchant ID', 'MODULE_PAYMENT_REALEX_ID', 'MerchantID', 'The merchant ID provided by realex', '6', '5', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Shared Secret', 'MODULE_PAYMENT_REALEX_SECRET', 'Secret', 'The Shared Secret provided by realex', '6', '4', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Transaction Currency', 'MODULE_PAYMENT_REALEX_CURRENCY', 'Selected Currency', 'The currency to use for credit card transactions', '6', '6', 'tep_cfg_select_option(array(\'Selected Currency\',\'Only USD\',\'Only CHF\',\'Only EUR\',\'Only GBP\',\'Only JPY\', \'Only HKD\', \'Only SEK\'), ', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Sort order of display.', 'MODULE_PAYMENT_REALEX_SORT_ORDER', '0', 'Sort order of display. Lowest is displayed first.', '6', '0', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Payment Zone', 'MODULE_PAYMENT_REALEX_ZONE', '0', 'If a zone is selected, only enable this payment method for that zone.', '6', '2', 'tep_get_zone_class_title', 'tep_cfg_pull_down_zone_classes(', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, use_function, date_added) values ('Set Order Status', 'MODULE_PAYMENT_REALEX_ORDER_STATUS_ID', '0', 'Set the status of orders made with this payment module to this value', '6', '0', 'tep_cfg_pull_down_order_statuses(', 'tep_get_order_status_name', now())"); } function remove() { tep_db_query("delete from " . TABLE_CONFIGURATION . " where configuration_key in ('" . implode("', '", $this->keys()) . "')"); } function keys() { return array('MODULE_PAYMENT_REALEX_STATUS', 'MODULE_PAYMENT_REALEX_ID','MODULE_PAYMENT_REALEX_SECRET', 'MODULE_PAYMENT_REALEX_CURRENCY', 'MODULE_PAYMENT_REALEX_ZONE', 'MODULE_PAYMENT_REALEX_ORDER_STATUS_ID', 'MODULE_PAYMENT_REALEX_SORT_ORDER'); } } ?>
-
A very belated thank you Tom for your help
-
Tom, As requested (sorry for the delay) the error message I'm receiving VPSProtocol=2.22 Status=OK StatusDetail=VSP Direct transaction from VSP Simulator. VPSTxId={DC6712B3-D48E-4EA7-A880-98C621EFED66} SecurityKey=VRTJ4XSIYD TxAuthNo=7171 AVSCV2=SECURITY CODE MATCH ONLY AddressResult=MATCHED PostCodeResult=NOTMATCHED CV2Result=MATCHED VPSProtocol=2.22&TxType=PAYMENT&Vendor=dargle123&VendorTxCode=5318126935841437& Amount=203.48&Currency=GBP&Description=Order+Number%3A+1&CardHolder=John+Me& CardNumber=4929000000006&StartDate=0305&ExpiryDate=0308&IssueNumber=&CV2=555& CardType=VISA&CustomerEMail=unbridledmarketing%40dsl.pipex.com& ContactNumber=01823+480589&BillingAddress=fairhaven%2C%0D%0A Beercrocombe%2C%0D%0ATaunton%2C%0D%0ASomerset%2C%0D%0AUnited+Kingdom& BillingPostCode=TA3+6AJ&DeliveryAddress=fairhaven%2C%0D%0ABeercrocombe%2C%0D% 0ATaunton%2C%0D%0ASomerset%2C%0D%0AUnited+Kingdom& DeliveryPostCode=TA3+6AJ&CAVV=&XID=&ECI=&ClientIPAddress=81.179.109.140& Basket=3%3AKilmartin+Chocolate+Milk%3A1%3A79.95%3A16.79%3A96.74%3A96.74%3A Baltimore%3A1%3A79.95%3A16.79%3A96.74%3A96.74%3A Shipping%3A1%3A10%3A----%3A10%3A10&3DSecureStatus=
-
Thanks for the info Tom. If I used a brain cell it might help at times! I have made the ammendment and the correct values are now being sent to Protx...(verified by checking in debug mode). However, I am now experiencing a VPSTxID error on both simulator and test servers. According to the Protx documentation that is down to a unique identifier that has not been sent from Protx....is that correct or am I not using that brain cell again ? Many thanks for your time...it is very much appreciated. John
-
Tom, Thanks for your reply. I rolled back to v2.4 due to all of the problems and have kept that version so I made the modification in includes\modules\payment\protx_direct.php at line 310 I sent a test Post through and I received the following error: Fatal error: Call to a member function on a non-object in /homepages/2/d179581832/htdocs/catalog/includes/modules/payment/protx_direct.php on line 310 I am pressuming that this would also have been returned if I had used it in V3 as well. Sorry for the delay in responding...Tax Return time! :angry:
-
Ok now I am able to send to Protx I have been running some test POSTS. I have installed v2.4a from version3 and am now experiencing a new problem. I have 3 currencies that a customer can choose from the default being the Euro. Everything is fine for posting Euro transactions yet if the currency is changed to one of the others i.e sterling the amount is shown correctly on screen (i.e it has been converted ok) the emailed invoice shows the correct value for the order yet the amount sent to Protx is the value in Euros but being charged in sterling. e.g Total cost £69.64 - value sent to Protx £103.74 (which is what it would be if it were in Euros). Any help most gratefully accepted. John
-
The problems I was having with the error message "Bank Unavailable" was in fact an error that was at the Protx end. Apparently, it was down to a TID number not being associated to the account which is a number that directs payment information to your bank. I thought it maybe useful to post this in case it happens to someone else as it has taken a very long time for the error to be found :blink:
-
Ok Tom...I appreciate your help...think for now I will try to go back to v2.4...should I use the URLS in that version?