![]() |
|
Adding comment problem - Printable Version +- ZenphotoCMS Forum (https://forum.zenphoto.org) +-- Forum: Support (https://forum.zenphoto.org/forum-1.html) +--- Forum: General support (https://forum.zenphoto.org/forum-4.html) +--- Thread: Adding comment problem (/thread-1957.html) |
Adding comment problem - sepkort - 2007-12-19 When adding comment Zp Demo Gallery you'll get error the following message: `Warning: Invalid argument supplied for foreach() in /home/www/zenphoto/zenphoto/zp-core/kses.php on line 429 Warning: Cannot modify header information - headers already sent by (output started at /home/www/zenphoto/zenphoto/zp-core/kses.php:429) in /home/www/zenphoto/zenphoto/zp-core/functions-controller.php on line 164 Warning: Cannot modify header information - headers already sent by (output started at /home/www/zenphoto/zenphoto/zp-core/kses.php:429) in /home/www/zenphoto/zenphoto/zp-core/functions-controller.php on line 169 ` The error is resulted by my demo site (ZP Version 1.1.3) as well as Zp Demo Gallery. Adding comment problem - sbillard - 2007-12-19 This is possibly because your zp-config.php file is missing the Adding comment problem - sepkort - 2007-12-20 Try to add a comment in demo-gallery http://www.zenphoto.org/zenphoto/demo-gallery/ and you'll see the error message. Adding comment problem - sbillard - 2007-12-20 Comments are working perfectly on my site. It is quite possible that the zenphoto demo gallery also is missing the allowed_tags. Did you check yours? Adding comment problem - Schnouki - 2007-12-20 There is definitely something weird with this kses.php thing. I had the same problem with a perfectly fine zp-config.php (1&1 host, PHP5, MySQL 5). I tried to debug it and found that the problem has something to do with getOption('allowed_tags') in functions-controller.php. Looks like it doesn't even return an array... I fixed this bug by adding "$inarray = getOption('allowed_tags');" in kses.php line 428. I don't get any warning anymore, but I don't think you really can consider this as a fix, it's just a workaround. Adding comment problem - sepkort - 2007-12-20 I installed the latest version: zenPHOTO 1.1.3 12/17/2007 and run the setup. My zp-config.php file includes the following lines: $conf['allowed_tags'] = array (
); ` The workaround by Schnouki gets the warning message out. The bug is still there... Adding comment problem - sbillard - 2007-12-21 The following comments refer to the nightly build only, not to the released 1.1.3 version. If you are running the 1.1.3 released version, check you config.php file for the code quoted by sepkort above. There is a change in how the html tags allowed for comments as processed by kses are handled. There is now an option for these rather than code in zp-config.php. first: the "fix" by Schnouki is not correct and should not be necessary. If you have not run setup.php, the kses allowed_tags option default will not have been set. This should be corrected, but does not seem to cause the errors you are describing. The only way I have been able to generate the error described above is by manually editing the database option table row for So, if you have run setup.php on the nightly build and are still having this problem you will need to delete the Adding comment problem - sepkort - 2007-12-22 I run setup.php on the nightly build and have no problem any more. Thanks! Adding comment problem - Elgar - 2007-12-22 I have this same problem (ish). With the current release AND the nightly build on IIS 5. If I attempt to add a comment it will add 26 duplicates of the same comment and then redirect to a blank page. Yes I have run setup.php and I've checked the allowed_tags. Adding comment problem - Elgar - 2007-12-22 I'd better add that I only get the same error as above if I comment out the header redirect, else I get multiple comment entries. Adding comment problem - sbillard - 2007-12-22 Elgar: Do you get any cgi errors? Kses.php's task is to screen the information posted for html tags. It does not appear to be involved in the redirect. It is strange that you get 26 duplicates. One would think that if the redirect is causing a repost, nothing would terminate the loop. How about a link to your site so we can take a look. Adding comment problem - Elgar - 2007-12-22 No errors. I'll turn comments back on so you can look. Adding comment problem - sbillard - 2007-12-22 OK, you can turn them off now. I got 54 repeats. For some reason, the POST information is not cleared by the redirect. You can try adding Adding comment problem - Elgar - 2007-12-23 I'm afraid unset($_POST); did nothing when placed right before header('Location: ' . $redirectTo); Adding comment problem - sbillard - 2007-12-23 Sorry, then, I am out of ideas. Adding comment problem - gregb34 - 2007-12-23 i got the same problem ... Adding comment problem - gregb34 - 2007-12-23 I have this error : Warning: Invalid argument supplied for foreach() in /var/www_data/zenphoto/zp-core/kses.php on line 429 Warning: Cannot modify header information - headers already sent by (output started at /var/www_data/zenphoto/zp-core/kses.php:429) in /var/www_data/zenphoto/zp-core/functions-controller.php on line 164 Warning: Cannot modify header information - headers already sent by (output started at /var/www_data/zenphoto/zp-core/kses.php:429) in /var/www_data/zenphoto/zp-core/functions-controller.php on line 169 But the comment is added. Adding comment problem - sbillard - 2007-12-23 gregb34: Please see my posting above regarding the allowed_tags array. Adding comment problem - gregb34 - 2007-12-23 I have installed the nighty buildand everything it's ok. THANKS !!! Adding comment problem - Elgar - 2007-12-24 No fix here. I've also noted that adding tags and descriptions does nothing. |