Nested DIV’s across functions in PHP, do not seem to work

The return command does exactly what it says, it returns the data and then returns back to the script. So, any lines after it will not be executed.

You have this function in your code:

function vc_make_graph() {       
    $db_handle = new DBController();
    # Show the customer dropdown ?>  
    <div id="overall"><?php
        $results = show_customer_dropdown($db_handle);
        if (isset($results))
            if (!results)
                return '<h6>Database query NOT successful!</h6><br/>';
        # Show dates
        show_dates();
        show_cars();?>
    </div><?php
    show_pushbuttons(); 
}

Let’s say the result is false, and the conditional is triggered. You will have this HTML output:

<div id="overall">

Which is an open DIV without a closing tag. This will mess up with the rest of the structure. Instead of return, use echo.