
Originally Posted by
iAkira
Well for one that class file must be Huge but looks decent :].
Are all PHP coders so lazy? This would take at most 30minutes to write, I don't see any need to post a thread about it. Sites I've done sometimes have classes with upwards of 1000 lines(usually an actual CMS).
Sure, you show off some extremely basic OOPHP, but I don't even see you passing variables by reference(not that this is necessary, but if you're showing off OOP...)
PHP Code:
class CSecure
{
static function Escape(&$var) // doesn't need to be dynamic
{
// sanitize $var
}
}
$username = $_POST['username'];
CSecure::Escape($username);
You could also show how your class initialization works, because that is a key in performance for large PHP sites. This is where OOP comes in, not at such simplistic levels unless purely for example.
Btw nice captcha...