Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Secpay PayPoint Issue


austenlennon

Recommended Posts

Hi,

 

I use PayPoint on my site.... payPoint works fine until you press 'Authorise' then I get this message. The payment and order goes through but the page goes here....

 

Can anyone help please?

 

 

 

Deprecated: Function split() is deprecated in /homepages/17/d163184393/htdocs/commerce/includes/modules/payment/paypoint_secpay.php on line 152

 

Warning: Cannot modify header information - headers already sent by (output started at /homepages/17/d163184393/htdocs/commerce/includes/modules/payment/paypoint_secpay.php:152) in/homepages/17/d163184393/htdocs/commerce/includes/functions/general.php on line 50

Link to comment
Share on other sites

The error is telling you what is going on: Function split() is deprecated . You can also check here

 

What to do? You can either use explode() or preg_split() , I guess that explode will do the job

 

How does your line 152 of file includes/modules/payment/paypoint_secpay.php look like?

Link to comment
Share on other sites

Multimixer - I very much appreciate your help. One only appreciates how little one knows when one is talking to someone who knows a lot. :-) (I sound like the Queen there)

 

I have no idea what you said in your last post.... I am a complete novice... :-) but here is the code from line 147 down....

 

 

function before_process() {

global $HTTP_GET_VARS, $HTTP_POST_VARS, $HTTP_SERVER_VARS;

 

if ( ($HTTP_GET_VARS['valid'] == 'true') && ($HTTP_GET_VARS['code'] == 'A') && !empty($HTTP_GET_VARS['auth_code']) && empty($HTTP_GET_VARS['resp_code']) && !empty($HTTP_GET_VARS[tep_session_name()]) ) {

$DIGEST_PASSWORD = MODULE_PAYMENT_PAYPOINT_SECPAY_READERS_DIGEST;

list($REQUEST_URI, $CHECK_SUM) = split('hash=', $HTTP_SERVER_VARS['REQUEST_URI']);

 

if ($HTTP_GET_VARS['hash'] != md5($REQUEST_URI . $DIGEST_PASSWORD)) {

tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, tep_session_name() . '=' . $HTTP_GET_VARS[tep_session_name()] . '&payment_error=' . $this->code ."&detail=hash", 'SSL', false, false));

}

} else {

tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, tep_session_name() . '=' . $HTTP_GET_VARS[tep_session_name()] . '&payment_error=' . $this->code, 'SSL', false, false));

}

}

 

function after_process() {

return false;

}

 

function get_error() {

global $HTTP_GET_VARS;

 

if ($HTTP_GET_VARS['code'] == 'N') {

$error = MODULE_PAYMENT_PAYPOINT_SECPAY_TEXT_ERROR_MESSAGE_N;

} elseif ($HTTP_GET_VARS['code'] == 'C') {

$error = MODULE_PAYMENT_PAYPOINT_SECPAY_TEXT_ERROR_MESSAGE_C;

} else {

$error = MODULE_PAYMENT_PAYPOINT_SECPAY_TEXT_ERROR_MESSAGE;

}

 

return array('title' => MODULE_PAYMENT_PAYPOINT_SECPAY_TEXT_ERROR,

'error' => $error);

}

Link to comment
Share on other sites

  • 5 months later...

Hold the fort - I fixed it. Some time ago I set my 1and1 server to php 5.4 - I thought I would reset it back down to 5.2 and low and behold it worked! wow..... thanks again for your help Multimix.......

 

That may fix it - but very temporately (deprecated functions are done for a reason) but it is not the answer.

 

George, lines 150 - 160 read:

 

 if ( ($HTTP_GET_VARS['valid'] == 'true') && ($HTTP_GET_VARS['code'] == 'A') && !empty($HTTP_GET_VARS['auth_code']) && empty($HTTP_GET_VARS['resp_code']) && !empty($HTTP_GET_VARS[tep_session_name()]) ) {
 $DIGEST_PASSWORD = MODULE_PAYMENT_PAYPOINT_SECPAY_READERS_DIGEST;
 list($REQUEST_URI, $CHECK_SUM) = split('hash=', $HTTP_SERVER_VARS['REQUEST_URI']);

 if ($HTTP_GET_VARS['hash'] != md5($REQUEST_URI . $DIGEST_PASSWORD)) {
	 tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, tep_session_name() . '=' . $HTTP_GET_VARS[tep_session_name()] . '&payment_error=' . $this->code ."&detail=hash", 'SSL', false, false));
 }
 } else {
 tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, tep_session_name() . '=' . $HTTP_GET_VARS[tep_session_name()] . '&payment_error=' . $this->code, 'SSL', false, false));
 }
}

 

explode does work as you suggest but I got a weird invoice with it:

 

post-192021-0-54893000-1382794252_thumb.jpgpost-192021-0-54893000-1382794252_thumb.jpg

 

Waiting for Monday now to check with PayPoint tech staff

Edited by Xpajun

My store is currently running Phoenix 1.0.3.0

I'm currently working on 1.0.7.2 and hope to get it live before 1.0.8.0 arrives (maybe 🙄 )

I used to have a list of add-ons here but I've found that with the ones that supporters of Phoenix get any other add-ons are not really neccessary

Link to comment
Share on other sites

Forget the latter half of my above post - the weird invoice is due to a customer discount that doesn't work properly :rolleyes:

 

At about line 152 of paypoint_secpay.php FIND:

 

list($REQUEST_URI, $CHECK_SUM) = split('hash=', $HTTP_SERVER_VARS['REQUEST_URI']);

 

REPLACE WITH:

 

list($REQUEST_URI, $CHECK_SUM) = explode('hash=', $HTTP_SERVER_VARS['REQUEST_URI']);

Edited by Xpajun

My store is currently running Phoenix 1.0.3.0

I'm currently working on 1.0.7.2 and hope to get it live before 1.0.8.0 arrives (maybe 🙄 )

I used to have a list of add-ons here but I've found that with the ones that supporters of Phoenix get any other add-ons are not really neccessary

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...