Skip Navigation

[Resolved] Undefined index: types-access/includes/Helper.php on line 3151

This support ticket is created 8 years, 3 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 8:00 – 17:00 8:00 – 17:00 8:00 – 17:00 8:00 – 17:00 8:00 – 17:00 -
- - - - - - -

Supporter timezone: America/Sao_Paulo (GMT-03:00)

Tagged: 

This topic contains 6 replies, has 3 voices.

Last updated by gaborN 7 years, 12 months ago.

Assisted by: Adriano.

Author
Posts
#351684

Hello,

Each wp-cli database operation generates two of these:
Notice: Undefined index: HTTP_HOST in /Users/guru/Documents/MAMP/szepelet/buyilike_woo/wp-content/plugins/types-access/includes/Helper.php on line 3151

This is because line 3151 contains this:

$url = "<em><u>hidden link</u></em>".$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI'];

And – I suppose – because the code is running in "cli mode", _SERVER does not have HTTP_HOST nor REQUEST_URI. But I might be mistaken. I do not know why wpcf_access_get_current_page() is executed when I use "wp-cle db", but as I get the notice, it is executed.

Anyway, can you please fix this issue in a future version of Access? It does not seem to do any "harm", but it is annoying since I use wp-cli a lot.

Thank you in advance,
G

#351854

Thank you for contacting us here in the Support Forum

I have forwarded the to our Access developer.

It might be that I will need further informations, but as you mention this happens on all WP DB CLI operations, it should be easy to replicate.

Please expect my informations here in the forum.

Thank you

#351859

Thank you Beda!

While we are at it, yesterday a noticed a similar issue again in types-access/includes/Helper.php.
This might be sort of an edge case, but I thought I should report it as well.

When I have the plugin called WP CSV activated (wordpress.org/plugins/wp-csv/), I get the following notice:
PHP Notice: Undefined index: post in .../wp-content/plugins/types-access/includes/Helper.php on line 3637

EDIT: the notice is generated when going to a strandard WP blog post page.

Meaning that the attribute 'post' is not available in:

$check_cap = $settings_access['post']['permissions'];

So we might need an isset() check or something else to resolve this issue, so please also forward this one to your Access developer so that he/she can take a look at it.

Thank you vary much,
G

#353174

Hello,

I have been escalated to this thread. I've created an issue for our Access development team. They will check it soon and we will publish a fix for that. Thank you for reporting this issue.

Please let me know if you are satisfied with my reply and any other questions you may have.

Regards,

Adriano Ferreira

#353431

Thank you for your kind help Adriano! Keep up the good work!

#353595

You are welcome.

#380414

Hi,
Any chance of resolving this? It has not yet been fixed.
Thanx in advance,

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.