On this page
- 1 Associative Array Example in PHP
- 2 Associative Array Example in PHP
- 2.0.0.1 CRUD App in PHP
- 2.0.0.2 Understanding PHP’s Array Manipulation: Exploring References and Unsetting
- 2.0.0.3 PHP built-in functions
- 2.0.0.4 Mastering Dependency Management with Composer: A Comprehensive Guid
- 2.0.0.5 Class and Object Example in PHP
- 2.0.0.6 PHP: Sum of two number
- 2.0.0.7 PHP How to get first and last name from full name?
- 2.0.0.8 How to create CSV file in PHP?
- 2.0.0.9 PHP: serialize() Function
- 2.0.0.10 Cheatsheet: PHP
- 2.0.0.11 PHP: global variable
- 2.0.0.12 Understanding PHP Error Reporting Configuration
- 2.0.0.13 PHP: Date and Time Function
- 2.0.0.14 PHP : Function
- 2.0.0.15 PHP: JSON Encode and Decode
- 2.0.0.16 PHP: Scrap Images Using cURL
- 2.0.0.17 What is curl in php?
- 2.0.0.18 PHP: Quiz App
- 2.0.0.19 PHP Tutorials
- 2.0.0.20 PHP: Arrays
- 2.1 Leave A Comment Cancel reply
Associative Array Example in PHP
Associative Array Example in PHP
July 29, 2023
<?php $data = array( 'name'=>"John Doe", 'age'=>20, "company_name"=> "XYZ" ); echo $data['name']. "\n"; echo $data['age']. "\n"; echo $data['company_name']. "\n"; ?>
Output:
$ php associative_array.php John Doe 20 XYZ