Insert into table problem?

Hey guys! So i’m trying to log information from a form into the database, but it’s not working for some reason. I’ve been looking over this code for too long, can someone else spot the error?

 public function log_client(){
        if($this->is_valid() == true){

            $log_client_query ='insert into client values("0","'.$this->name.'","'.$this->sex.'","'.$this->age.'","'.$this->doctor.'");';
            $log_client = $this->link->query($log_client_query);


                if($this->log_info() == true){
                    echo "success";
                    if($this->send_email() == true){
                        echo "successful";
                        echo "failure";
                    echo "failure";

                echo "An Insert Error Has Occurred";

I’m passing the is_valid() check, but not the insert into database check. Any suggestions?

Do you get an error?

no errors except the ones i create with the if statements

Can you show us the declaration for $this->link? If it is a class, can you post the class?

the link is a private variable that’s initialized in the __contruct. it looks like this:

class process{
    private $link;
    private $name;
    private $age;
    private $sex;
    private $doctor;
    private $errors;

    public function __construct(){
    $this->age = $this->validate(intval($_POST['age']));
    $this->name = $this->validate($_POST['name']);
    $this->doctor = $this->validate($_POST['doctor']);
    $this->sex = $_POST['sex'];
    $this->errors = array();
    $this->link = new mysqli(host','user','password','db');

Try outputting $this->link->error, see if that gives any additional details.