Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Fatal error: Call to a member function setFieldNamePrefix() on a non-object
 
jonathanjarman
Jr. Member
 
Total Posts:  1
Joined:  2011-11-27
 

I’m currently sandboxing PayPal UK (website payments pro) and the express checkout returns with the following error:

Fatal error: Call to a member function setFieldNamePrefix() on a non-object in /home4/ampmdire/public_html/app/design/frontend/base/default/template/paypal/express/review.phtml on line 28

I’m using a custom theme (avalanche) and Magento version is 1.7.0.1.

Does anyone know how to fix this error?

I’ve deleted (renamed) paypal.xml from the theme folder (as suggested in other posts) but this has not worked.

 
Magento Community Magento Community
Magento Community
Magento Community
 
mailamiton
Jr. Member
 
Total Posts:  7
Joined:  2011-06-30
 

I have also got the same issue . any suggestions ?

 
Magento Community Magento Community
Magento Community
Magento Community
 
mailamiton
Jr. Member
 
Total Posts:  7
Joined:  2011-06-30
 

Can anybody help here please!!!!!!!!!!!!!!!

 
Magento Community Magento Community
Magento Community
Magento Community
 
lam09
Jr. Member
 
Total Posts:  3
Joined:  2010-07-08
 

I have been tearing my hair out over this and found that sometimes simply renaming the problem xml file doesnt fix the problem so you need to take the API details out and then put them back again.  Heres what just worked for me:

1) Rename paypal.xml to paypal._xml within “app/design/frontend/YOURTHEME/default/layout/” (mag 1.7)

2) Remove the paypal API credentials from the config and save

3) Put the API credentials back again and save

Hope it works for you guys

 
Magento Community Magento Community
Magento Community
Magento Community
 
Elavarasan
Jr. Member
 
Avatar
Total Posts:  1
Joined:  2012-04-30
Chennai
 

Hello guys ,
Finally i found the problem. Its all about the layout file. I am also having the same problem. the review page is working fine in default theme. and it doesn’t work any other theme (I just checked 2 more themes).

So i just copy the default layout xml ( app->design->frontend->base-> default->layout->paypal.xml ) file to current theme file ( app->design->frontend->default->YOUR THEME->layout->paypal.xml )

Thats all..Its working fine to me..!!  grin

 
Magento Community Magento Community
Magento Community
Magento Community
 
heathbr
Jr. Member
 
Total Posts:  10
Joined:  2010-07-28
 

I am having the same problem after upgrading from 1.6 to 1.7.0.2. I tried removing the paypal.xml file but that didn\’t work ... anything else I should try?

Thanks!

 
Magento Community Magento Community
Magento Community
Magento Community
 
heathbr
Jr. Member
 
Total Posts:  10
Joined:  2010-07-28
 

I am having the same problem after upgrading from 1.6 to 1.7.0.2. I tried removing the paypal.xml file but that didn\\\’t work ... anything else I should try?

Thanks!

 
Magento Community Magento Community
Magento Community
Magento Community
 
krishana
Member
 
Total Posts:  37
Joined:  2011-04-27
Jaipur
 

Solution for this problem

In your packeage/theme/layout/paypal.xml

need little change

View

<block type="paypal/express_review" name="paypal.express.review" template="paypal/express/review.phtml">

Then after add some other blocks

<block type="paypal/express_review_billing" name="express.review.billing" as="billing" template="paypal/express/review/address.phtml"/>
<block type="paypal/express_review_shipping" name="express.review.shipping" as="shipping" template="paypal/express/review/address.phtml"/>
<block type="paypal/express_review" name="express.review.shipping.method" as="shipping_method" template="paypal/express/review/shipping/method.phtml"/>

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top