@samara
In CodeIgniter, you can print an associative array using the print_r()
function.
Here's an example:
1 2 3 4 5 6 7 8 9 |
$data = array( 'name' => 'John Doe', 'age' => 30, 'email' => '[email protected]' ); echo '<pre>'; print_r($data); echo '</pre>'; |
This code will output the associative array in a formatted way, making it easier to read. You can include this code in your controller or view file in CodeIgniter to print the associative array.