$Data = M ($action); Instantiate the data model
$this->data = $Data->field (' Id,datupian,touxiang,content,nike,time ')->select ();
Returns a two-dimensional array
For example, get datupian field content is www.baidu.com/22.jpg is the network image address I want to file_get_content this field content to re-overwrite the original field content how to get
Reply to discussion (solution)
Directly with update, usage
$m =m (' Tbale '); Table name $data[' id ']=98; The first value must be the updated condition, that is, the table's primary key, that is, the condition to be updated $data[' type ']= ' the value to update '; After the first condition, the value of the sub-segment to be modified is then $data[' type2 ']= ' 2 to update the value '; $data [' Type3 ']= ' 3 value to be updated '; $m->save ($data); Finally, you can update it with the Save method. After the update, a value is returned, which you can print out to determine.
Directly with update, usage
$m =m (' Tbale '); Table name $data[' id ']=98; The first value must be the updated condition, that is, the table's primary key, that is, the condition to be updated $data[' type ']= ' the value to update '; After the first condition, the value of the sub-segment to be modified is then $data[' type2 ']= ' 2 to update the value '; $data [' Type3 ']= ' 3 value to be updated '; $m->save ($data); Finally, you can update it with the Save method. After the update, a value is returned, which you can print out to determine.
I don't have to keep it in the database.!!!!!!!!! I just tried to change the array values directly.
What do you mean???