I'm in a small pickle on this one. I'm using Codeigniter controller.
I need to update an Order status where "DATA HERE" is located in the code below.
Basically here is what i need to do locate the $orderid within a table called "orders" find the "status" and update it to the text "Paid".
$orderid = $id;
if($this->input->post("status")=="OK" && $this->input->post("step")=="Confirmation" && $this->input->post("orderhash")==$orderHashOrg)
{
// DATA HERE
}
Any help is greatly appreciated.
Here is my current code
$updateData=array("status"=>"Paid");
if($this->input->post("status")=="OK" && $this->input->post("step")=="Confirmation" && $this->input->post("orderhash")==$orderHashOrg)
{
$d = $this->db->get('offers_orders');
$this->db->select('status');
$this->db->where('order_number', $id);
$orderdata = $d->result_array();
$this->db->update("offers_orders", $updateData);
}