diff --git a/application/controllers/info_amp.php b/application/controllers/info_amp.php index 8c0e6937..3bd85daf 100644 --- a/application/controllers/info_amp.php +++ b/application/controllers/info_amp.php @@ -22,6 +22,7 @@ class Info_amp extends CI_Controller $json = $this->input->post('json'); $html = $this->input->post('html'); $css = $this->input->post('css'); + $script = $this->input->post('script'); $status = $this->input->post('status'); if ($icid && $json && $html) { try { @@ -46,6 +47,13 @@ class Info_amp extends CI_Controller } else { $this->InfoMetas_model->update($icid, 'AMP_CSS', $css); } + //script + $meta = $this->InfoMetas_model->get($icid, 'AMP_SCRIPT'); + if ($meta === false) { + $this->InfoMetas_model->add($icid, 'AMP_SCRIPT', $script); + } else { + $this->InfoMetas_model->update($icid, 'AMP_SCRIPT', $script); + } //status $meta = $this->InfoMetas_model->get($icid, 'AMP_STATUS'); if ($meta === false) { diff --git a/application/views/bootstrap3/information_edit.php b/application/views/bootstrap3/information_edit.php index 3b20223c..27d5db37 100644 --- a/application/views/bootstrap3/information_edit.php +++ b/application/views/bootstrap3/information_edit.php @@ -538,7 +538,7 @@