Undefined property: stdClass::$cookie - php

How do I resolve this error?
/var/www/html/cy_prestashop/modules/taxcloud/taxcloud.php: 1178",
"(Notice) Undefined property: stdClass::$cookie"

Notice are not errors that stop the normal shop function. You can see it because you have active Prestashop DEBUG MODE.
Anyway, the problem is a bad programming of your module taxcloud located in line 1178 as your error said. You must look for a developer help if this problem affect your shop behavior.
Good luck.

Related

phpstan and psalm ail because of an unidentifiable problem

For a php project, for some time my tests fail for phpstan and psalm, with unclear error messages.
I tried to debug, to rebuild the commits, but without success. I can't understand or so.
These are the output, the composer.json and the ci.yml.
I can spot these lines. For psalm:
Uncaught Error: Call to undefined method ReflectionUnionType::getName() in phar:///home/runner/work/me-tools/me-tools/vendor/psalm/phar/psalm.phar/src/Psalm/Internal/Codebase/Reflection.php:262
And for phpstan:
PHP Warning: Undefined array key "PHPStan\Rules\Arrays\DuplicateKeysInLiteralArraysRule" in phar:///home/runner/work/me-tools/me-tools/vendor/phpstan/phpstan/phpstan.phar/vendor/nette/utils/src/Utils/Reflection.php on line 180
Warning: Undefined array key "PHPStan\Rules\Arrays\DuplicateKeysInLiteralArraysRule" in phar:///home/runner/work/me-tools/me-tools/vendor/phpstan/phpstan/phpstan.phar/vendor/nette/utils/src/Utils/Reflection.php on line 180
PHP Fatal error: Uncaught TypeError: _HumbugBox5f943a942674\Nette\Utils\Reflection::getUseStatements(): Return value must be of type array, null returned in phar:///home/runner/work/me-tools/me-tools/vendor/phpstan/phpstan/phpstan.phar/vendor/nette/utils/src/Utils/Reflection.php:180
But I didn't help and even looking on the net I didn't find anything useful.
The strangest thing is that I can't replicate this problem. In fact, locally, with the same configuration, I have no problem.
One possible hypothesis about that Call to undefined method ReflectionUnionType::getName () is that somewhere there might be something like:
public function myMethod(): int | float
but I have checked the code and I am not aware of any of this.
Can anyone help me debug?
These are unrelated separate problems. You’ll have higher luck asking about them in Psalm and PHPStan GitHub issue trackers.

Undefined property: stdClass::$name in /opt/.../wp-admin/includes/plugin-install.php

I have been following this tutorial to deploy a WordPress plugin through Github. After setting up everything.
I get an error
Undefined property: stdClass::$name in /opt/.../wp-admin/includes/plugin-install.php on line 621
In the plugin infobox. What could I be doing wrong?
Try adding $response->name = $this->pluginData["Name"]; to function setPluginInfo. I think you could remove $response->plugin_name.... Perhaps there was a change since that guide was written back in 2014.

How to correct and change a static method to a non-static method for Joomla module

I updated a client's Joomla from J2.5.28 to J3.6.4. I have corrected most of the errors but this one stumps me even after researching here. I'm a novice PHP programmer and know enough to fix a few things here and there. I researched this throughout the internet and on StackOverflow and simply do not understand how to fix the following error in my particular case. I understand I could just turn off error reporting; However I do not want to do that because [from what I did find] this doesn't actually solve the problem. Solving the problem and correcting the code is what is actually recommended.
Here is the error:
Strict Standards: Non-static method modBtContentShowcaseHelper::fetchHead() should not be called statically in ...modules/mod_bt_contentshowcase/mod_bt_contentshowcase.php on line 64
Line 64 reads as follows:
modBtContentShowcaseHelper::fetchHead( $params );
I would like to know how to correct this.
Note: Upgrading this extension is not an option because it was customized by the developer of the extension and an upgrade would wipe everything out. Contacting them usually takes several days to get a response and I need to get this corrected
Thanks in advance for the help!
You need to initiate the class modBtContentShowcaseHelper
$x = new modBtContentShowcaseHelper();
$x->fetchhead($params);

The Bug Genie 'undefined function make_url()'

PHP Fatal error: Call to undefined function thebuggenie\core\helpers\make_url() in ../core/helpers/TextParser.php on line 706
This is the error that I keep getting when trying to set up the VCS-integration successfully in The Bug Genie. It is an issue tracker that has VCS (git) integration. The commits can be linked to a project, and with the correct commit-message to the right issue using a git-hook. Then you can view the commit in the issue tracker. Apparently the commit is getting linked to the project, but it doesn't get linked to the issue because of the error. Can anybody help me?
The source code on GitHub.
Thanks in advance!
I've found the solution. There appears to be an error in the vcs-integration. Apparently the ui.inc.php-library is not loaded when using the git-hook.
So the temporary solution (until they solve it) is:
At modules/vcs_integration/Vcs_integration.php:226, add:
framework\Context::loadLibrary('ui');
As far as i see, make_url function is defined in a global namespace, but is called from namespace thebuggenie\core\helpers. So i suppose that's your problem

getting notice in php file while executing

what is the meaning of undefined property DOMElement::$node Vaoue
I searched in google I didn't get any annswer for this.
what is the meaning of undefined property DOMElement::$node Vaoue
It simple means that you have a undefined property DOMElement in your code.
To Help you in details we realy like to se more from the code which causes the error
Well, a good start would be to post the code you're trying to execute. Anyways most likely, a property you're trying to access is undefined.

Categories