1. I have an array array(1,2,3); I need it to become a negative number when inserting it into the database
2. The front-end input table displays a positive number, and the back-end becomes a negative number before inserting it into the database. How to achieve this?
$arr1 = array(1,2,3);
$arr2 = array();
foreach($arr1 as $v){
}
Loop, take negative value and save to database