WPIntell

Source evidence

PHP warning

Pricing Table WordPress Plugin – Easy Pricing Tables · support · 2021-07-24T07:45:00+00:00

mixedsentiment
highseverity
0.95relevance
12replies
Evidence linked to opportunitycommercial context

Proof Health

Open evidence

Commercial opportunities need traceable source links before they are treated as build-worthy.

3 / 31 rows with source links

9.7% of this page's analysis has direct source links.

0 build-decision rows missing links

0 rows here require auditable proof before promotion.

28 rows with no attached evidence

0 rows have source counts but still need direct links.

Conversation

support
pikamander2 resolved
This code: if ( function_exists( 'register_block_type' ) ) { register_block_type( 'fatcatapps/easy-pricing-tables', array( 'editor_script' => array( 'fca_ept_editor_script','jquery-ui-dialog' ), 'editor_style' => 'fca-ept-editor-style', 'style' => array( 'fca-ept-layout1-style', 'fca-ept-layout2-style' ), 'render_callback' => 'fca_ept_render', )); } is causing this warning to appear in our error log whenever we visit the wp-admin editing screen of one of our custom post types: PHP message: PHP Warning: explode() expects parameter 2 to be string, array given in /home/public_html/wp-includes/class.wp-dependencies.php on line 169 It appears that you’re not allowed to pass an array to style . This topic was modified 4 years, 10 months ago by pikamander2 . Based on this page , maybe it’s supposed to be named ‘styles’ instead? Based on this page , it looks like you’re supposed to pass style a single string and then you can use styles to pass additional styles via an array. editor_script also seems to expect a single string. I haven’t seen any warnings/errors there yet, but I don’t think you’re supposed to be passing it an array either. Hi Pikamander2, Thanks for your message. I hope you had a good weekend. Our development team is working on a fix for this and will soon have a plugin update to solve this issue. I will message back here when it is ready. Thanks again for letting us know. In the meantime, if there is anything else, don’t hesitate to get back to us. All the best. Hi Pikamander2, Thanks for your patience. We have updated Easy Pricing Tables to take care of your previously mentioned issue. If you encounter any further problems, don’t hesitate to get to us. All the best and have a good weekend. Hey Pikamander2, I hope all is well. I am going to mark this as “resolved” but if you have any more issues, feel free to reach out to us again. All the best. Hi @gavinohanlon – It looks like this warning is occasionally appearing in the error log now: PHP Warning: count(): Parameter must be an array or an object that implements Countable in /home/public_html/wp-content/plugins/easy-pricing-tables/includes/settings.php on line 9 Here’s the relevant line, which is part of the dh_ptp_settings_menu function: $position = count( $submenu_list ) -1; It looks like we’re using a “legacy pricing table”, so I’m not sure if that’s related to the PHP warning at all. Hey Pikamander2, Thanks for your message and bringing this up. To help us trouble shoot this better, could you let us know where you are seeing the issue or what you are doing when the error shows up. When I take a quick look through when I am using the plugin, I don’t see this error. Looking forward to hearing back from you. All the best. I just received a similar warning from the WordPress built-in feature that detects when a plugin or theme causes a fatal error on your site: An error of type E_ERROR was caused in line 9 of the file /[…]/wp-content/plugins/easy-pricing-tables/includes/settings.php. Error message: Uncaught TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in /[…]/wp-content/plugins/easy-pricing-tables/includes/settings.php:9 Hi Mojamba, Thanks for your message. It might be better to start your own thread for this one as per the forum rules – https://wordpress.org/support/forum-user-guide/faq/#i-have-the-same-problem-can-i-just-reply-to-someone-elses-post-with-me-too To help us trouble shoot this better, could you give us more details about the issue or what you are doing when the error shows up. Is that the exact message you get ? Or are there some details missing from your error message, e.g. on the /[…]/ part ? Looking forward to hearing back from you. All the best. Thanks. I did as you suggested and created a new topic.

Comments

12 shown
pikamander2 2021-07-24T07:52:00+00:00

Based on this page , maybe it’s supposed to be named ‘styles’ instead?

pikamander2 2021-07-24T07:56:00+00:00

Based on this page , it looks like you’re supposed to pass style a single string and then you can use styles to pass additional styles via an array.

pikamander2 2021-07-24T07:59:00+00:00

editor_script also seems to expect a single string. I haven’t seen any warnings/errors there yet, but I don’t think you’re supposed to be passing it an array either.

gavinohanlon 2021-07-26T11:15:00+00:00

Hi Pikamander2, Thanks for your message. I hope you had a good weekend. Our development team is working on a fix for this and will soon have a plugin update to solve this issue. I will message back here when it is ready. Thanks again for letting us know. In the meantime, if there is anything else, don’t hesitate to get back to us. All the best.

gavinohanlon 2021-07-30T07:35:00+00:00

Hi Pikamander2, Thanks for your patience. We have updated Easy Pricing Tables to take care of your previously mentioned issue. If you encounter any further problems, don’t hesitate to get to us. All the best and have a good weekend.

gavinohanlon 2021-08-06T08:59:00+00:00

Hey Pikamander2, I hope all is well. I am going to mark this as “resolved” but if you have any more issues, feel free to reach out to us again. All the best.

pikamander2 2021-08-19T08:16:00+00:00

Hi @gavinohanlon – It looks like this warning is occasionally appearing in the error log now: PHP Warning: count(): Parameter must be an array or an object that implements Countable in /home/public_html/wp-content/plugins/easy-pricing-tables/includes/settings.php on line 9 Here’s the relevant line, which is part of the dh_ptp_settings_menu function: $position = count( $submenu_list ) -1;

pikamander2 2021-08-19T08:30:00+00:00

It looks like we’re using a “legacy pricing table”, so I’m not sure if that’s related to the PHP warning at all.

gavinohanlon 2021-08-23T13:56:00+00:00

Hey Pikamander2, Thanks for your message and bringing this up. To help us trouble shoot this better, could you let us know where you are seeing the issue or what you are doing when the error shows up. When I take a quick look through when I am using the plugin, I don’t see this error. Looking forward to hearing back from you. All the best.

mojamba 2022-01-31T03:06:00+00:00

I just received a similar warning from the WordPress built-in feature that detects when a plugin or theme causes a fatal error on your site: An error of type E_ERROR was caused in line 9 of the file /[…]/wp-content/plugins/easy-pricing-tables/includes/settings.php. Error message: Uncaught TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in /[…]/wp-content/plugins/easy-pricing-tables/includes/settings.php:9

gavinohanlon 2022-01-31T13:13:00+00:00

Hi Mojamba, Thanks for your message. It might be better to start your own thread for this one as per the forum rules – https://wordpress.org/support/forum-user-guide/faq/#i-have-the-same-problem-can-i-just-reply-to-someone-elses-post-with-me-too To help us trouble shoot this better, could you give us more details about the issue or what you are doing when the error shows up. Is that the exact message you get ? Or are there some details missing from your error message, e.g. on the /[…]/ part ? Looking forward to hearing back from you. All the best.

mojamba 2022-01-31T14:32:00+00:00

Thanks. I did as you suggested and created a new topic.