Posts by Guilherme Andrade • 15 points
2 posts
-
1
votes1
answer273
viewsQ: Trying to get the 'id' property of non-imposition with Array
I’m trying to get an ID from the database, but I get the following error: Trying to get Property 'id' of non-object... My code: if($provider == null) { $provider = array( 'provider' =>…
-
-1
votes2
answers54
viewsQ: Sorts PHP Array Frequency
I would like to know how to order this Array, placing the repeated numbers at the end. $arr = array( 5, 4, 2, 3, 2, 1 ); sort ($arr); foreach ($arr as $n => $valor) { echo "$valor\n"; }…