checkout problem with custom theme in magento after selecting the payment method continue button doesnot work and onepage checkout become freezed

If you are using Magento 1.4.1 or just upgraded any of your old Magento sites to the latest Magento version, then you may be getting a very weird error on your checkout page, that the checkout CONTINUE button on payment screen, either on or PayPal , just doesn’t work.

The cause of this error is, Magento Team has introduced a new JavaScript file, which validates the credit card numbers, etc on the payment screen.

So, if you are using the default theme, then you should not get this problem.

But if you are using any custom theme, then you have to do some changes on your files.

Few symptoms of this problem is, you will see such errors,

Please verify the card with the issuer bank


Unable to initialize Express Checkout review.


CONTINUE button on Credit Card Form doesn’t work.

I will give the instructions in details below, how to fix this issue :

Just add this js in your page.xml:

<action method="addJs"><script>lib/ccard.js</script></action> under <block type="page/html_head" name="head" as="head">

replace it with

  <action method="addJs"><script>prototype/prototype.js</script></action>
  <action method="addJs" ifconfig="dev/js/deprecation"><script>prototype/deprecation.js</script></action>
  <action method="addJs"><script>lib/ccard.js</script></action>


<action method="addJs"><script>lib/ccard.js</script></action> under
<block type="page/html" name="root" output="toHtml" template="page/print.phtml">
  <block type="page/html_head" name="head" as="head">

Replace it with

 <action method="addJs"><script>prototype/prototype.js</script></action>
  <action method="addJs"><script>mage/translate.js</script></action>
  <action method="addJs"><script>lib/ccard.js</script></action>

This must solve your complete problem .

But in case, its still not working, then here is another fix, which I got from another member from a forum,

I was experiencing the same issue: Nothing happens when you enter the credit card information and hit continue. After investigating with Firebug, it seemed that the method verify Credit Card was not defined in validation.js.

You can fix this by pasting the following JavaScript code into validation.js under js->prototype in root folder:

/ Credit Card Validation JavaScript

 function validateCreditCard(s) {
  // remove non-numerics
  var v = "0123456789";
  var w = "";
  for (i=0; i < s.length; i++) {
  x = s.charAt(i);
  if (v.indexOf(x,0) != -1)
  w += x;
  // validate number
  j = w.length / 2;
  k = Math.floor(j);
  m = Math.ceil(j) - k;
  c = 0;
  for (i=0; i<k; i++) {
  a = w.charAt(i*2+m) * 2;
  c += a > 9 ? Math.floor(a/10 + a%10;) : a;
  for (i=0; i<k+m; i++) c += w.charAt(i*2+1-m) * 1;
  return (c%10; == 0);

Now you have to disable Mage_Centinel from backend system->configuration->advanced to make it work in Mozilla and Firefox.

But it will work on IE without disabling centinel module.