Jump to content
Sign in to follow this  
gadgetfox

Authorize.net Consolidated 1.7b -- javascript CVV

Recommended Posts

Minor, but annoying problem with the Authorize.net Consolidated 1.7b Curlfix contribution... Wondering if anyone has tangled with (and resolved) this:

 

The link to bring up the CVV information via <A HREF="java script:CVVPopUpWindow"> on the checkout screen does not seem to want to work in Mozilla Firefox. It works in Internet Explorer, but returns a javascript error in the information bar.

 

For the time being, I've just turned it into a normal HREF URL with a "target=_blank" tag so that it will work for everyone, but does anyone know what Javascript bugaboo is rearing its ugly head here?

Share this post


Link to post
Share on other sites

This is a little late but it still might apply to others. A solution to the pop up window (It also doesn't work on Macs) is to relocate the CCVPopUpWindow javascript down with the other javascript on the page.

 

 

 

Delete

#######

<script language="javascript" type="text/javascript">!--

/********************************

* Addition for Authorize.net Consolidated

* by Austin519 - CVV PopUp Window

* If using a custom checkout_payment.php

* paste the following lines into your file

********************************/

function CVVPopUpWindow(url) {

window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,res

izable=no,copyhistory=no,width=600,height=233,screenX=150,screenY=150,top=150,lef

t=150')

}

//--></script>

#######

 

 

Insert this code - see below

##################

 

/********************************

* Addition for Authorize.net Consolidated

* by Austin519 - CVV PopUp Window

* If using a custom checkout_payment.php

* paste the following lines into your file

********************************/

function CVVPopUpWindow(url) {

window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,res

izable=no,copyhistory=no,width=600,height=233,screenX=150,screenY=150,top=150,lef

t=150')

}

 

 

###################

 

Existing Javascript

#############

 

<script language="javascript"><!--

 

<<<Insert above code here>>>

 

 

var selected;

 

 

#############

 

A hat's off to Austin519 for this contribution. It ties up a lot of the loose ends found in the eariler versions of the Authorize.net AIM modules.

Share this post


Link to post
Share on other sites

I still cannot get this to work here is my code:

 

<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">
<title><?php echo TITLE; ?></title>
<base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>">
<link rel="stylesheet" type="text/css" href="stylesheet.css">
<script language="javascript">
function CVVPopUpWindow(url) {
window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,res
izable=no,copyhistory=no,width=600,height=233,screenX=150,screenY=150,top=150,lef
t=150')
}
var selected;

function selectRowEffect(object, buttonSelect) {
 if (!selected) {
if (document.getElementById) {
  selected = document.getElementById('defaultSelected');
} else {
  selected = document.all['defaultSelected'];
}
 }

 if (selected) selected.className = 'moduleRow';
 object.className = 'moduleRowSelected';
 selected = object;

// one button is not an array
 if (document.checkout_payment.payment[0]) {
document.checkout_payment.payment[buttonSelect].checked=true;
 } else {
document.checkout_payment.payment.checked=true;
 }
}

function rowOverEffect(object) {
 if (object.className == 'moduleRow') object.className = 'moduleRowOver';
}

function rowOutEffect(object) {
 if (object.className == 'moduleRowOver') object.className = 'moduleRow';
}
//--></script>

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×