When a user tries to register an event, it fails with this error message:
Fatal error: Call to a member function SetForm() on a non-object in /home/utahgu5/public_html/wp-content/plugins/events-made-easy/eme_payments.php on line 206
We are using 2Checkout but the payment button doesn’t show up. Note that the registration IS recorded, but it fails to show the payment button.
The “SetForm()” function is indeed found in the eme_payments.php file, in the “eme_2co_form()” function. The problem is, it seems, that SetForm() is only used for WebMoney payments, NOT 2CO payments.
I am able to fix the problem by removing this line entirely from the eme_2co_form() method:
$form_html .= $wm_request->SetForm(false);
The problem is, of course, that “$wm_request” is a non-object because it belongs to WebMoney, not 2CO.
I don’t know why this line is in the 2CO method, but removing it makes everything work again.