why have I an error in the visual constructor? - php

I have an error notice in the visual constructor of my web page (jupiter)
That error says:
Warning: Illegal string offset 'pro_widgets' in /home/customer/www/gedysa.com/public_html/wp-content/plugins/elementor/includes/api.php on line 164
Warning: Illegal string offset 'pro_widgets' in /home/customer/www/gedysa.com/public_html/wp-content/plugins/elementor/includes/api.php on line 167
I have gone where apparently the problem is, in the php archive of jupiter plugin and it look like this:
164 $data['pro_widgets'] = [];
165 }
166
167 return $data['pro_widgets'];
but I dont know what to do.
Could somebody help me??

Related

Wordpress fatal error when editing post and using accent/non english letters

I updated w wordpress blog site to 6.0.1 and everything is okay except the post editing page doesn't load in (fatal error), when I use non english letters like "á".
If I create a new post and I write the content to "a" it is good.
Then if I change it to "á" it is bad.
If I deactivate the block editor in the user profile and I create a new post and I write "a" it is good.
If I then change it to "á" it is good.
Something is bad with the block editor.
The character coding of the tables and columns are utf8mb4_unicode_ci.
The php version is 7.4.
The MySQL version is 5.5.5-10.5.15-MariaDB.
Things I have tried:
deactivated every plugin
changed themes to twntytwentytwo
Notice:
Trying to access array offset on value of type null in blog/wp-content/plugins/wp-hide-post/admin/settings/class_settings.php
on line 324
Notice:
Undefined offset: 0 in blog/wp-includes/class-wp-block.php
on line 224
Notice:
Trying to get property 'parsed_block' of non-object in blog/wp-includes/class-wp-block.php
on line 228
Notice:
Trying to access array offset on value of type null in blog/wp-includes/block-supports/elements.php
on line 100
Notice:
Trying to get property 'parsed_block' of non-object in blog/wp-includes/class-wp-block.php
on line 233
Notice:
Trying to get property 'parsed_block' of non-object in blog/wp-includes/class-wp-block.php
on line 236
Notice:
Trying to access array offset on value of type null in blog/wp-includes/blocks/gallery.php
on line 20
Notice:
Trying to access array offset on value of type null in blog/wp-includes/blocks/latest-posts.php
on line 234
Notice:
Trying to access array offset on value of type null in blog/wp-includes/blocks/navigation.php
on line 666
Warning:
Creating default object from empty value in blog/wp-includes/class-wp-block.php
on line 236
Notice:
Undefined property: stdClass::$context in blog/wp-includes/class-wp-block.php
on line 239
Fatal error: Uncaught Error: Call to undefined method stdClass::render() in blog/wp-includes/class-wp-block.php:241
Stack trace:
#0 blog/wp-includes/blocks.php(901): WP_Block->render()
#1 blog/wp-includes/blocks.php(939): render_block(Array)
#2 blog/wp-includes/class-wp-hook.php(307): do_blocks('

joomla getting notices when try to run my project

When I am trying to run my joomla project it give me list of notice with some warning.
Notice: Array to string conversion in /var/www/html/gms/libraries/framework/Joomla/Registry/Registry.php on line 419
Notice: Array to string conversion in /var/www/html/gms/libraries/framework/Joomla/Registry/Registry.php on line 421
Notice: Array to string conversion in /var/www/html/gms/libraries/framework/Joomla/Registry/Registry.php on line 424
Notice: Array to string conversion in /var/www/html/gms/libraries/framework/Joomla/Registry/Registry.php on line 428
Dont't know how to solve it

PHP disable error from specific file?

I am getting hundreds of from ANSI.php. Here is an example:
/usr/share/pear/File/ANSI.php on line 553 Notice: Undefined offset: 75 in
/usr/share/pear/File/ANSI.php on line 555 Notice: Undefined offset: 76 in
/usr/share/pear/File/ANSI.php on line 553 Notice: Undefined offset: 76 in
/usr/share/pear/File/ANSI.php on line 555 Notice: Undefined offset: 77 in
/usr/share/pear/File/ANSI.php on line 555 Notice: Trying to get property of non-object in
/usr/share/pear/File/ANSI.php on line 496 Notice: Trying to get property of non-object in
This is generating from:
$ansi->appendString($ssh->read());
Everything is working. I suspect the old machines I am working with are giving ANSI.php a hard time.
Is there a way i can disable just the error messages from ANSI.PHP and keep the others? Unless someone has a way of fixing the error.
Simplest Solution (Sub-Optimal)
I guess the simplest way to suppress the errors would be to use the error suppression operator #. eg.
#$ansi->appendString($str);
Optimal Solution (Possibly)
There have been two commits to phpseclib since the latest release (1.0.7 and 2.0.6, as of this post) that fixed issues with File/ANSI.php:
https://github.com/phpseclib/phpseclib/commit/5c792f6bc1fa8a5d26b43fb8200191c073637e15
https://github.com/phpseclib/phpseclib/commit/84d1628cb7734134b1ba80545b38985025942b79
More info:
https://github.com/phpseclib/phpseclib/issues/1161
https://github.com/phpseclib/phpseclib/issues/1150
Kinda makes me wonder if one of those might fix the issue for you.
Fallback to Optimal Solution
If the previously mentioned "optimal solution" doesn't fix the issue for you then it would be nice to fix the problem at the source. What'd help me do that would be a copy of the data you got before you passed it to $ansi->appendString(). To make it so the characters don't get garbled because they're extended ASCII maybe hex encode it. eg. echo bin2hex($ssh->read()); or something.

PHP Warning: simplexml_load_string(): Entity: line 1: parser error : Start tag expected, '<' not found [duplicate]

I am using PHP for the first time. I am using the php sample for uploading image on ebay sandbox. I am getting the following error on running the PHP file:
PHP Warning: simplexml_load_string(): Entity: line 1: parser error : Start tag expected, '<' not found in /home/nish/stuff/market place/test/php5/UploadImage/UploadSiteHostedPictures.php on line 69
PHP Warning: simplexml_load_string(): HTTP/1.1 200 OK in /home/nish/stuff/market place/test/php5/UploadImage/UploadSiteHostedPictures.php on line 69
PHP Warning: simplexml_load_string(): ^ in /home/nish/stuff/market place/test/php5/UploadImage/UploadSiteHostedPictures.php on line 69
PHP Notice: Trying to get property of non-object in /home/nish/stuff/market place/test/php5/UploadImage/UploadSiteHostedPictures.php on line 92
PHP Notice: Trying to get property of non-object in /home/nish/stuff/market place/test/php5/UploadImage/UploadSiteHostedPictures.php on line 93
PHP Notice: Trying to get property of non-object in /home/nish/stuff/market place/test/php5/UploadImage/UploadSiteHostedPictures.php on line 93
PHP Notice: Trying to get property of non-object in /home/nish/stuff/market place/test/php5/UploadImage/UploadSiteHostedPictures.php on line 94
PHP Notice: Trying to get property of non-object in /home/nish/stuff/market place/test/php5/UploadImage/UploadSiteHostedPictures.php on line 94
Relevant lines are:
69. $respXmlObj = simplexml_load_string($respXmlStr); // create SimpleXML object from string for easier parsing
// need SimpleXML library loaded for this
92. $ack = $respXmlObj->Ack;
93. $picNameOut = $respXmlObj->SiteHostedPictureDetails->PictureName;
94. $picURL = $respXmlObj->SiteHostedPictureDetails->FullURL;
What I can understand is the respXMLObj is not getting set properly. I have checked that simleXML support is enabled.
Could someone please help me debug this. Thanks
The code you refer to has this line:
//curl_setopt($connection, CURLOPT_HEADER, 1 ); // Uncomment these for debugging
it seems like you uncommented these. This will result in getting the HTTP header in your response. Which is OK for debugging, but it will create an XML parse error in simplexml_load_string.
Either comment it out again or put 0 as its value.
In my case. I just removed the invisible character The BOM in the beginning of the XML file. How to do it - depends on your text editor.
$hasError = false;
if ( $resp == 'Internal Server Error' || empty($resp) )
{
$hasError = true;
}
if ( ! $hasError )
{
$aux = !empty($resp) ? explode('', $resp) : NULL;
$temp = utf8_decode(trim($aux[0]));
$xml = simplexml_load_string($temp);
}
Do a var_dump($respXmlStr); my guess is that this string is not valid XML.
As per the simplexml-load-string documentation, the first parameter is expected to be A well-formed XML string - http://php.net/manual/en/function.simplexml-load-string.php

Magento "Notice: Undefined variable: response"

I'm running Magento 1.6.2.0.
I noticed in system.log every time an order is placed these 3 lines:
2012-12-19T15:37:00+00:00 ERR (3): Recoverable Error: Argument 1 passed to Mage_Core_Controller_Varien_Action::__construct() must be an instance of Zend_Controller_Request_Abstract, array given, called in /chroot/home/saucench/saucencheese.com/html/app/code/core/Mage/Core/Model/Config.php on line 1351 and defined in /chroot/home/saucench/saucencheese.com/html/app/code/core/Mage/Core/Controller/Varien/Action.php on line 138
2012-12-19T15:37:00+00:00 ERR (3): Recoverable Error: Argument 2 passed to Mage_Core_Controller_Varien_Action::__construct() must be an instance of Zend_Controller_Response_Abstract, none given, called in /chroot/home/saucench/saucencheese.com/html/app/code/core/Mage/Core/Model/Config.php on line 1351 and defined in /chroot/home/saucench/saucencheese.com/html/app/code/core/Mage/Core/Controller/Varien/Action.php on line 138
2012-12-19T15:37:00+00:00 ERR (3): Notice: Undefined variable: response in /chroot/home/saucench/saucencheese.com/html/app/code/core/Mage/Core/Controller/Varien/Action.php on line 141
So apparently the variable "response" isn't defined. Would anyone be able to help me locate the source that's causing this error? It can't be in the Config.php or Action.php since I've never modified those.
Thank you.
It's on this file
/chroot/home/saucench/saucencheese.com/.../Core/Controller/Varien/Action.php
on line 141
See what is happening there and make sure the $variables are defined.

Categories