OK. I'm new to Classes in PHP and trying to pass variables into the protected functions in the class. How do I do this?
CLASSES.PHP
<?php
    include($_SERVER['DOCUMENT_ROOT']."/includes/con.php");
    class gindex {
        protected function rdev($a,$b,$c,$d){
            $d = base64_encode($d);
            mysql_query("INSERT INTO mem(first_name,last_name,email,password,type) VALUES(".$a.",".$b.",".$c.",".$d.",'developer')", $db);
    }
?>
INDEX.PHP
<?php
    include($_SERVER['DOCUMENT_ROOT']."/includes/con.php");
    if(isset($_POST['developerbtn'])){
        $fname = $_REQUEST['fname'];
        $lname = $_REQUEST['lname'];
        $email = $_REQUEST['email'];
        $password = $_REQUEST['password'];
        $Cgindex = new gindex();
        $Cgindex->rdev($fname,$lname,$email,$password);
    }
?>
 
     
     
     
     
     
     
     
    