Bienvenido, Invitado
Recordarme

TEMA:

Paypal button doesn't work - ff_btnPaypal_action is not defined 7 meses 1 semana antes #266018

  • Avatar de Admin@opendofe.org Autor del tema
  • Admin@opendofe.org
  • Fuera de línea
  • Junior Breezer
  • Junior Breezer
  • Mensajes: 62
  • Gracias recibidas: 0
Hi
I am trying to click on a paypal button, and it doesn't take me to Paypal.
In the JS console, I get an error
"ReferenceError: ff_btnPaypal_action is not defined"

Where do I start looking for the ff_btnPaypal_action code?

Thanks
Mike
Mike

Por favor, Identificarse o Crear cuenta para unirse a la conversación.

Paypal button doesn't work - ff_btnPaypal_action is not defined 7 meses 1 semana antes #266021

  • Avatar de Admin@opendofe.org Autor del tema
  • Admin@opendofe.org
  • Fuera de línea
  • Junior Breezer
  • Junior Breezer
  • Mensajes: 62
  • Gracias recibidas: 0
I found the ff_btnPaypal_action() - it's the Paypal button.
The error message appears to be erroneous.

Here's my paypal code:
function ff_btnPaypal_action(element, action) {
    switch (action) {
        case 'click':
            prod = ff_getElementByName('selMembership');
            prod1= prod.options[prod.selectedIndex].innerHTML;
            n = prod1.indexOf('£');
            m = prod1.length;
            item = prod1.substr(0,n);
            itemcost = prod1.substr(n+1,m-n);
            qty=ff_getElementByName('selQty').value;
            cost = itemcost*qty;
            ff_getElementByName('rdCost').value = cost;
            if (qty==1) {pers = ' person '} else {pers = ' persons '}
            if (qty>1) {ea = 'each'} else {ea = ''}
            paypal =  item + ' - '  + qty + pers + '@£' +  itemcost + ea + '|0|' + cost + '|0';
            ff_getElementByName('PaypalSelect').value = paypal;
            ff_validate_submit();
            break;
    } 
}

The ff_validate_submit() isn't executing, although I can't see why not.
Mike

Por favor, Identificarse o Crear cuenta para unirse a la conversación.

Paypal button doesn't work - ff_btnPaypal_action is not defined 7 meses 1 semana antes #266028

  • Avatar de Admin@opendofe.org Autor del tema
  • Admin@opendofe.org
  • Fuera de línea
  • Junior Breezer
  • Junior Breezer
  • Mensajes: 62
  • Gracias recibidas: 0
You can close this case - I had a custom validation with no JS code associated wityh it that was causing the validation to fail, but as it had no code, it didn't issue any errors messages regarding the validation!
Thanks for your time.
Mike

Por favor, Identificarse o Crear cuenta para unirse a la conversación.

Paypal button doesn't work - ff_btnPaypal_action is not defined 7 meses 1 semana antes #266031

  • Avatar de tihana.krivic
  • tihana.krivic
  • Fuera de línea
  • Moderator
  • Moderator
  • Mensajes: 10535
  • Karma: 3
  • Gracias recibidas: 705
Hi,

ok :)

If you need anything else, feel free to ask

Regards,
Tihana

Por favor, Identificarse o Crear cuenta para unirse a la conversación.

  • Página:
  • 1
Moderadores: ForumSupport
Tiempo de carga de la página: 0.042 segundos