I get an error message like this.
Fatal error: Cannot use string offset as an array in D:\www\site\inc ludes\change_pr eference.inc.ph p on line 310
[PHP]$cityName["$i"]["$j"] = $row2['city'];[/PHP]
The above code is causing this error. Please let me know what is wrong with this code. How can I rectify this error.
Here $i, $j consists of integer value. which are used to perform a for loop specific number of times. while $row2 brings data from a database.
Fatal error: Cannot use string offset as an array in D:\www\site\inc ludes\change_pr eference.inc.ph p on line 310
[PHP]$cityName["$i"]["$j"] = $row2['city'];[/PHP]
The above code is causing this error. Please let me know what is wrong with this code. How can I rectify this error.
Here $i, $j consists of integer value. which are used to perform a for loop specific number of times. while $row2 brings data from a database.
Comment