Pages (2): 1 2   
Member
Member
vincent3569   05-07-2017, 07:54
#1

Hi,

I often have this warning in my debug log.
I can't figure where is the matter.

Do you have an idea?

WARNING: Cannot modify header information - headers already sent by (output started at /home/avbo7291/public_html/zenphoto/themes/zpArdoise/inc_header.php:8) in /home/avbo7291/public_html/zenphoto/zp-core/functions-common.php on line 499 setcookie called from zp_setCookie (functions-common.php [499]) from getUserLocale (functions-i18n.php [444]) from htmlmetatags::getHTMLMetaData (html_meta_tags.php [183]) from call_user_func_array (unknown) from zp_apply_filter (functions-filter.php [149]) from include (inc_header.php [9]) from include (pages.php [3]) from include (index.php [130]) from index.php [28]
the line 8 of inc_header.php is the following, as other official themes (like zenpage):

[quote]

[b]
Administrator
Administrator
acrylian   05-07-2017, 08:17
#2

Official 1.4.14 or support build? In the latter there has been a small change in cookie handling (to be exact the parameters they are setup). Try clearing all cookies via the browser and try again please.

Member
Member
vincent3569   05-07-2017, 08:56
#3

I use official 1.4.14.
For sure, I can clearing all my cookies, but I can't do that for all my vistors.
This message is in english, so I suspect my vistor to not be me :-)
Btw, I have some messages in french, some en english.

Administrator
Administrator
acrylian   05-07-2017, 12:27
#4

Of course you cannot clear cookies for visitors. This was just in case you used the support build and actually only should affect the actual main login cookies.

I will take a look but never saw this as far as I remember. Is there any locale printed in the charset meta?

Member
Member
MarkRH   06-07-2017, 23:38
#5

Wonder if some bot was snooping around looking for various things and called some php file that normally isn't called directly?

I'd compare that entry with the webserver's access logs to see what was being called when that happened.

I haven't seen this one myself.

I usually get some warning about ADMIN_RIGHTS not being defined.

Member
Member
sbillard   06-07-2017, 23:45
#6

You should look in your server's PHP error log. The error basically says that something has been output already so setting a cookie is not allowed. So what is needed is to find out what has been output. Probably an error message or such that cannot be trapped by Zenphoto.

Member
Member
vincent3569   07-07-2017, 06:22
#7

I have no error on the debug log that I can access on my prod server :-(

If could be usefull, I can hack zenphoto core files to log something in debug log but you have to point me in the right direction.

Member
Member
vincent3569   07-07-2017, 06:25
#8

Today, I have onother NOTICE in my debug log :

NOTICE: Undefined index: path in /home/avbo7291/public_html zenphoto/zp-core/zp-extensions/dynamic-locale.php on line 92 printLanguageSelector called from include (inc_header.php [240]) from include (404.php [1]) from include (404.php [43]) from include (index.php [135]) from index.php [28]

Administrator
Administrator
acrylian   07-07-2017, 07:35
#9

That error is related to the url request path to switch languages. So it might very well be like MarkRH suspects that someone is trying to set a language that is not existing somehow or some spam bot is trying to do things he is not supposed to do.

Member
Member
sbillard   07-07-2017, 16:03
#10

It would be really useful to see the actual request URI for these errors. You can add code to debugLogBacktrace() to include this in the log. The "correct" code is a bit long for this post, but you can adapt it from the ZenPhoto20 release where it has been present for a while.

It the first case, there is some issue with the initial establishment of the language. So when getHEMLMetaData calls getUserLocale() the latter thinks it needs to set the locale cookie, but it is too late in the process as the theme has already started output. (ZenPhoto20 no longer uses this flawed implementation of getUserLocale().)

The second error implies that parse_url() did not return a path item. I really don't know how that is possible, thus it would be nice to see the actual url that was used.

Pages (2): 1 2   
  
Powered By MyBB, © 2002-2026 MyBB Group.
Made with by Curves UI.