/** * Saves media order for one parent * * @param string parent type. Can be 'page', 'article' * @param string parent ID * */ public function save_ordering($parent, $id_parent) { $order = $this->input->post('order'); if ($order !== FALSE) { // Clear the cache Cache()->clear_cache(); $this->media_model->save_ordering($order, $parent, $id_parent); // Answer $this->success(lang('ionize_message_operation_ok')); } else { $this->error(lang('ionize_message_operation_nok')); } }