Forum Moderators: coopster

Message Too Old, No Replies

Wordpress: PHP script error

kses.php file problem

         

milan oberoy

8:40 am on Jul 3, 2008 (gmt 0)

10+ Year Member



I have discuss the same problem on wordpress forum (http://wordpress.org/support/topic/186502?replies=1) but according to my early experience we hardly get any solution from there. So, I am discussing it here (I don't know whether its allowed).

when I set 'define('CUSTOM_TAGS', false);' in kses.php file. I can't leave comment with html tags. when I set it to 'true' it shows below error on top of my blog (when opening blog in browser)....

Warning: Invalid argument supplied for foreach() in /home/myusername/public_html/blog/wp-includes/kses.php on line 780

However I can comment with html tag (when it is true).

also, a person with same name, email, website and ip can not comment on more than 1 post, it will show 404 error otherwise. However people can comment as many time without entering website url no matter name, email, website-name andip is same.

Any php master are there who can show me solution?

eelixduppy

2:40 pm on Jul 3, 2008 (gmt 0)



Not sure specifically what is wrong with WP itself, however, the warning you are getting from PHP suggests that you don't have an array within your foreach loop. Not sure where this is coming from, though, but obviously it has to do with the custom_tags constant.

From my quick research I've seen that a few other people have had trouble with this file as there seems to be some bugs present in the current WP file. There is a sourceforge replacement [sourceforge.net] for this file that you might want to give a try. If it fixes it for you then you'll be set, otherwise you are going to have to do more investigation to see where this error is coming from. You should start by checking to see what's going on on line 780 and see why the custom_tags constant has anything to do with it.

Good luck

milan oberoy

2:34 pm on Jul 4, 2008 (gmt 0)

10+ Year Member



okey, now what I found is everything (yes everyting) is fine if I don't enter http:// in url field.