When you have just 1 class, it doesn't really come into perspective...the fact that you're modularizing your code is one of the many bonuses of OOP. Here's your code, cleaned up, with an added Database class: class DB{ private $query; public function __construct(){} /** * Save a user preference */ public function SaveUserPreference($table, $values, $where){ $this->dbConnect(); # Build the query $this->query = "INSERT INTO VALUES "; if( !empty($table) ) $this->query .= $table; if( !empty($values) ) $this->query .= "VALUES(" . $values . ") "; if( !empty($where) ) $this->query .= "WHERE " . $where; mysql_query($this->query); } /** * Clean data using mysql_real_escape_string */ public function cleanData($data){ return mysql_real_escape_string($data); } /** * Create a mysqli connection */ private function dbConnect(){} } And here's your Language class, which extends class DB, so that it can use its methods: class Language extends DB{ public $language, $isLogged; public function __construct(){ parent::__construct(); } public function setPost($_POST){ $this->language = $this->cleanData($_POST); } /** * If the user tries to change the language */ function setLanguage(){ if( !empty($this->language['lang']) ){ $_SESSION['lang'] = $this->language['lang']; # If logged, save the language into user preferences in db if ($this->isLogged == 1) $this->SaveUserPreference("users(`lang`)", $this->language, "user=".$User); } else { if ( !empty ($_SESSION['lang']) ) # If the session exists $this->language = $_SESSION['lang']; # Assign the session language to variable $Lang. else # If it doesn't exist $this->language = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2); # Get it from the browser # If the language is not supported (or still doesn't exist), then put "en" as default. Supported so far: en, es. if ( $this->language !== "en" && $this->language !== "es") $this->language = "en"; } } /** * Return the right name of the language. * @Ref: http://www.w3schools.com/tags/ref_language_codes.asp * @Ref: http://web.forret.com/tools/html.asp */ public function GetLanguage($arg){ switch ($arg){ case "bn": return "বাংলা"; break; # Bengali case "de": return "Deutsch"; break; # German case "en": return "English"; break; # English case "es": return "Español"; break; # Spanish [Español] case "fr": return "Français"; break; # French [Français] case "it": return "Italiano"; break; # Italian [Italiano] case "ja": return "日本語"; break; # Japanese case "pt": return "Português"; break; # Portuguese [Português] case "ru": return "русский"; break; # Russian [???????] case "zh": return "简体中文"; break; # Simplified chinese [????] default: return "English"; break; # return English } } } Good, now lets use our classes. Note that we only initialize the parent class, and we don't need to init the DB class separately because we can call the DB methods from the parent class. #Initialize our class $r = new Language; # Build a fake post for testing $_POST = array('lang' => 'en', 'asa' => 54); # Set options $r->setPost($_POST); $r->isLogged = 1; # Set Language $r->setLanguage(); Now that we've saved our users language preferences, let's see what the long form is: # Now, get the long version of the user language echo $r->GetLanguage($r->language); That was easy! And no need to write a mysql_query here and there, just write once and forget about it. We have a set of classes that is modular, abstract, and the parent class inherits methods from its child classes, so no need to reinitialize a DB class, we can just recycle the language class (although in many cases, you shouldn't do this). OOP is good in some cases, not all. You wouldn't bring a gun to a tickle-fight, would you? Your use of OOP completely depends on what your project is and how big it is, amongst other things. By the way, here's the above code in action: http://juanleonardosanchez.com/data/sandbox/php/test.php You can give it different codes via GET: http://juanleonardosanchez.com/data/sandbox/php/test.php?lang=fr