Jump to:

113 Posts in 155 Topics by 53 members

Payments and Payment Gateway / APIs

SilverStripe Forums » Payments and Payment Gateway / APIs » Payment Module Error ($fields undefined)

This is a forum for discussing SilverStripe can-do payments and their APIs / Gateways.

Moderators: martimiz, Sean, Normann, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 641 Views
  • lennonrich
    Avatar
    Community Member
    2 Posts

    Payment Module Error ($fields undefined) Link to this post

    Hello all

    I've recently inherited a website that we were told was complete, however it still has a few kinks that I'm trying to figure out (I'd never touched SilverStripe before this) but there's one that's completely stumped me with the payment gateway. After adding items to the cart and pressing "Place order and make payment", I get the following error:


    Direct link

    I've tried following through the information provided in the Trace section, as well as various Google options, but not being familiar with SilverStripe I don't know if I'm following serious leads or dead ends, and so I'm hoping someone here could point me in the right direction

    Many thanks for your help in advance!

  • svandragt
    Avatar
    Community Member
    43 Posts

    Re: Payment Module Error ($fields undefined) Link to this post

    As far as I can tell from that screenshot, the $fields variable is not declared so PHP cannot append an array item to it.
    Somewhere earlier in that method you should ensure there is a line like

    $fields = array();

  • lennonrich
    Avatar
    Community Member
    2 Posts

    Re: Payment Module Error ($fields undefined) Link to this post

    Heya,

    Thanks for this. I did try this earlier, but then it caused the entire site not to load (was giving Server 500 errors). As soon as I removed the declaration the site came back.

    641 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.