When Customer place order with CODE payment method it show this error
Fatal error: Call to a member function getTypeInstance() on a
non-object in
/home/store/public_html/app/code/core/Mage/Catalog/Block/Product/View/Abstract.php
on line 44
Any one can help please?
Related
I am working on Woocommerce with Wordpress V 4.5. I am getting below error only for one product rest products are working fine.
Fatal error: Call to a member function is_type() on a non-object in
/home/example/public_html/wp-content/themes/dss/woocommerce/cart/cart-item-data.php
on line 35
I am integrating magento payumoney gateway.I am using payumoney extension available on payumoney website.But it's through this error
Fatal error: Call to a member function getMethodInstance() on a non-object in D:\xampp\htdocs\build\store\app\code\core\Mage\Payment\Model\Observer.php on line 46
on this url
http://localhost/build/store/index.php/payucheckout/shared/redirect/
for this I follow this https://magento.stackexchange.com/questions/31517/magento-fatal-error-call-to-a-member-function-getmethodinstance-on-a-non-obje
but can't understand what going on.
my website observer code
$order = $observer->getEvent()->getOrder();
if ($order->getPayment()->getMethodInstance()->getCode() != 'free') {
return $this;
}
to remove this error i have update my magento from old version to new please help to find out.
On manage product page, I'm getting no grid, I traced it and it shows the error
Fatal error: Call to a member function setFormFieldName() on a non-object in /app/code/core/Mage/Adminhtml/Block/Catalog/Product/Grid.php on line 279
I don't know whats wrong with it.
I think the FieldName value is invalid, it should be $this->getMassactionBlock()->setFormFieldName('product_id');
I am trying to display the price of each product in the search it works for most products but when I search for a piticular product I keep getting this error
Fatal error: Call to a member function getpricehtml() on a non-object in /home/public_html/wp-content/theme/search.php on line 76
this is the only search I get the error on "CUP0501-001 2822505 Jacobsen Reel Motor WMSM4".
Here is the line on the search page that is giving me trouble
getpricehtml(); ?>
Any help would be appreciated.
In this file $product is not defined, so define it.
This code might solve your problem.
global $woocommerce;
$product = new WC_Product(get_the_ID());
echo $product->get_price_html(); //Shows the price
I am new to opencart, so please help me.
I am using opencart version 1.5.6, now whenever I edit and delete the product it shows me
Fatal error: Call to a member function productUpdateListen() on a non-object in /home/crazepur/public_html/admin/controller/catalog/product.php on line 78
and
Fatal error: Call to a member function deleteProduct() on a non-object in /home/crazepur/public_html/admin/controller/catalog/product.php on line 133 respectively.
Although it edit and delete the product.
Please help me how to fix it.
Code in Line 78 $this->openbay->productUpdateListen($this->request->get['product_id'], $this->request->post);
And code in line 133 $this->openbay->deleteProduct($product_id);
This means $this->openbay is not an object which contains function productUpdateListen() & deleteProduct(), probably it's NULL or false in some cases (nothing found) due to it's not accessible. Out of scope.
Try
var_dump($this->openbay);
Check the O/P
it's simple and the error-message says it all: your $this->openbay doesn't have those methods (productUpdateListen() and deleteProduct()) - most likely it isn't an object at all.
please debug your code since it's impossible to say what's going wrong wich so little information. to start, do a var_dump($this->openbay); right before the function-calls and check the output.