Linked Questions
38 questions linked to/from 'Notice: Array to string conversion in...' error
1 vote
2 answers
45k views
Array to string conversion error [duplicate]
I have a query that's pulling a list of IDs. Those IDs are in an array and I need to search another table with those IDs. I tried using implode to make those IDs a string that I could use in a where ...
0 votes
1 answer
6k views
Can't echo JSON Array in PHP [duplicate]
I can't access my json and would like to know where the error is. $json = json_encode($data); // string(1065) "[{"id":"test123","key":["one",... Then I decode it to make it accessable via this ...
2 votes
1 answer
10k views
fputcsv Notice: Array to string conversion [duplicate]
I have a simple PHP code to save JSON to CSV , but I have an error, this the code: <?php $inputJSON = file_get_contents('https://url'); $out = fopen('C:\xampp\htdocs\tkp_product\tkp2.csv', 'w'); ...
0 votes
1 answer
2k views
php function returns "Warning: Array to string conversion in" [duplicate]
I have the following PHP function where I am trying to explode an array and apply foreach loop on it to get a collective set of data. However, I am getting the error quoted in the subject. function ...
-1 votes
1 answer
557 views
php artisan route:list errorException [duplicate]
I get the following error when performing the following command php artisan route: list I updated the RouteServiceProvider.php file. I am looking for the route admin.edit that does not detect it May ...
0 votes
1 answer
616 views
php : Array to string conversion [duplicate]
im trying to return an array of messages but i get this error : Notice: Array to string conversion in ($sql="select UTLR_UID from adm_utilisateurs where UTLR_LOGIN='$user' and UTLR_MDP='$mdp'";) ...
0 votes
1 answer
387 views
mysqli_fetch_assoc only returning one result, even though there is more [duplicate]
When I ran the following query in PHPMyAdmin, it returned the correct number of results. However when I try to echo the results in PHP, it only outputs one result, even when there is more thn one. How ...
0 votes
1 answer
310 views
My foreach loop is not retrieving the key value pairs even though Javascript sends the correct data [duplicate]
When I submit the button through ajax(axios), I manage to send the following data to Laravel as far as the console prints: {name: "task", fields: Array(2)} fields: Array(2) 0: {_token: "...
0 votes
1 answer
209 views
Array to string conversion what is error please suggest me [duplicate]
I get error Array to string conversion my controller is function index() { if ($this->input->post('submit') != NULL) { $data = array(); $data['username'] = $this-...
-2 votes
1 answer
159 views
I can't transform sum to integer in PHP [duplicate]
I have this code to extract sum of column records in mysql <?php $query = "select sum(sell) from store where sell!=0"; $result = $crud->getData($query); $total_s = implode(" ",$result); ...
0 votes
0 answers
206 views
"Array to string conversion" and "Undefined property: stdClass::$Array" notices [duplicate]
I'm getting the above referenced notices, which prevent from seeing/enter values in certain WP fields. The responses here available to similar problems are not working in my case. Thanks in advance ...
-2 votes
1 answer
269 views
Error Exception Array to string conversion [duplicate]
I want to have a response in postman for my API... but when I send a raw in body of postman I faced to array to string conversion error Error Exception (E_NOTICE) Array to string conversion this is ...
0 votes
1 answer
48 views
How to work (create and access) empty 2D array in PHP [duplicate]
I want to define in PHP a new 2D array (to fill and access it later in cycle) but I have problem to deal with it. I went through some articles (e.g. here), but it still does not work for me. My code ...
-3 votes
1 answer
99 views
WARNING: Array to string conversion in C:/Path-of-my-website/prispevky/photos.php on line 150 [duplicate]
i have on line 150.. $sql = "UPDATE " . TABLEP . " SET alt='$_POST[alt]', text='$_POST[text]', nadpis='$_POST[nadpis]', datum='$_POST'datum', odkaz='$_POST[odkaz]', urltext='$_POST[...
0 votes
2 answers
60 views
Php printing data from database [duplicate]
I am trying to get the data from the database, but there is a problem printing it out function getData($connection) { $query = "SELECT Email FROM SUBSCRIPTIONS"; $result =...