PDA

View Full Version : checking validation from php



Jeff Wheeler
June 26th, 2004, 10:48 PM
Hey,

I'm having people submit to my database code that should be valid (it's gonna be put on a page that should be valid is a better way to say that), it'll include paragraphing that's automatically done but also allows people to insert any of there own html.

So my question is if there is any way to check that my page will validate before putting it into my mysql database?

If so any help implementing this would be greatly appreciated (but not nescessary).

Cheers,
Jeff C:-) :toad: :be: (I love smileys)

Jeff Wheeler
June 27th, 2004, 02:51 AM
wow, not one reply? I feel so unimportant :upset: :tb:

Hans Kilian
June 27th, 2004, 05:13 AM
Give us a chance. Some of us are at sleep at 5 AM in the morning :)

I hope you trust these people that will enter HTML. They can do all sorts of nasty things if they want to. That's why most forums use BBcode instead. That way they can limit what kind of tags the users can use.

But as for your question, you can install the validator.w3.org service locally: http://validator.w3.org/docs/users.html#Installing

The license looks a lot like the GPL license, so you should be free to modify it so it'll suit your needs.

But it'll probably not be a small job...

Jeff Wheeler
June 27th, 2004, 11:40 AM
that's an awesome idea, I have no idea how you found that but thank's a gazillion