Ik ken niks over het maken van 3d grafieken maar zou het willen leren kennen.
Is er iemand die kan helpen met het opbouwen ervan.
Ik heb vogende code en een array al.
<?php
$host = "localhost"; /// use default
$username = "root"; /// write your mysql username
$password = ""; /// write your mysql password
$database = "test"; /// write your mysql database
$conn=mysqli_connect($host, $username, $password,$database) or die (mysqli_error());
// Controleren op verbinding
if ($conn->connect_error) {
die("Connection failed: " . $conn->connect_error);
}
// Query uitvoeren om gegevens op te halen
$query = "SELECT land, `cache type`, COUNT(*) as aantal_caches FROM database_bel GROUP BY land, `cache type`";
$result = $conn->query($query);
// Verzamel gegevens voor de grafiek
$data = [];
while ($row = $result->fetch_assoc()) {
$data[$row['land']][] = [
'type' => $row['cache type'],
'count' => $row['aantal_caches']
];
}
echo '<pre>'.print_r($data, true).'</pre>';
?>
uit deze array krijg ik het volgende :
[Cyprus] => Array
(
[0] => Array
(
[type] => Multicache
[count] => 5
)
[1] => Array
(
[type] => Unknown Cache
[count] => 30
)
[2] => Array
(
[type] => Wherigo Cache
[count] => 2
)
)
[Denemarken] => Array
(
[0] => Array
(
[type] => Letterbox
[count] => 1
)
[1] => Array
(
[type] => Multicache
[count] => 40
)
[2] => Array
(
[type] => Unknown Cache
[count] => 4953
)
[3] => Array
(
[type] => Wherigo Cache
[count] => 3
)
)
Is er nu iemand die deze array kan overbrengen naar een 3d grafiek AUB.
Dank bij voorbaat .
Ps Ariën -> chatgpt weet er geen raad mee, alees wat deze weergeeft zijn fouten zonder grafiek op scherm.
Daarom stel ik hier de vraag aan de professionals.
Dank bij voorbaat.