Made a query to the database:
$val = DB::table('users')->select('downloads')->where('id', 1)->get();
And received:
[{"downloads":3}]
How to get 3 ?
3
Judging by the conclusion: $val[0]->downloads
$val[0]->downloads
Source: https://ru.stackoverflow.com/questions/870471/More articles:How to get a specific php array value?wordpress plugin can not get doppolya recordsDI Symfony in FactoryHelp me decide what to do.Extract strings and numeric values from a text fileHow to access the site if its dns is disabled?Why gives an error (IndexError: string index out of range)Write text from an array to iconContent and balloonHeaderThe appearance of the button more when exceeding the number of charactersWordPress, change the position “Cancel reply” in the form of commentsAll Articles