Commit 1d13a904 by Trần Văn Minh

Thêm kiểu của ảnh khi upload

parent 1b81795e
...@@ -72,7 +72,7 @@ class CmsTrack extends CI_Controller ...@@ -72,7 +72,7 @@ class CmsTrack extends CI_Controller
$this->form_validation->set_rules( $this->form_validation->set_rules(
'title', 'title',
'Số ngày diễn ra cuộc thi', 'Tên bài hát',
'trim|required|xss_clean' 'trim|required|xss_clean'
); );
...@@ -113,7 +113,7 @@ class CmsTrack extends CI_Controller ...@@ -113,7 +113,7 @@ class CmsTrack extends CI_Controller
$upload_full_path = '/home/aseanvn/public_html/vmusicchart.dcv.vn/' . $upload_path; $upload_full_path = '/home/aseanvn/public_html/vmusicchart.dcv.vn/' . $upload_path;
$config['upload_path'] = $upload_full_path; $config['upload_path'] = $upload_full_path;
$config['file_name'] = md5($track_id.time()); $config['file_name'] = md5($track_id.time());
$config['allowed_types'] = 'gif|jpg|png'; $config['allowed_types'] = 'gif|jpg|png|jpge';
$config['max_size'] = 20480; $config['max_size'] = 20480;
$config['max_width'] = 1024; $config['max_width'] = 1024;
$config['max_height'] = 768; $config['max_height'] = 768;
...@@ -168,7 +168,7 @@ class CmsTrack extends CI_Controller ...@@ -168,7 +168,7 @@ class CmsTrack extends CI_Controller
$this->_data['title'] = $this->input->post('title'); $this->_data['title'] = $this->input->post('title');
$this->_data['singer'] = $this->input->post('singer'); $this->_data['singer'] = $this->input->post('singer');
$this->_data['artist'] = $this->input->post('artist'); $this->_data['artist'] = $this->input->post('artist');
$this->_data['img'] = $this->input->post('image_path'); $this->_data['avatar'] = $this->input->post('avatar');
// //
$this->_data['functionName'] = 'Tạo mới Bài hát'; $this->_data['functionName'] = 'Tạo mới Bài hát';
$this->_data['action'] = 'addTrack'; $this->_data['action'] = 'addTrack';
...@@ -199,7 +199,7 @@ class CmsTrack extends CI_Controller ...@@ -199,7 +199,7 @@ class CmsTrack extends CI_Controller
$upload_full_path = '/home/aseanvn/public_html/vmusicchart.dcv.vn/' . $upload_path; $upload_full_path = '/home/aseanvn/public_html/vmusicchart.dcv.vn/' . $upload_path;
$config['upload_path'] = $upload_full_path; $config['upload_path'] = $upload_full_path;
$config['file_name'] = md5($insert_id.time()); $config['file_name'] = md5($insert_id.time());
$config['allowed_types'] = 'gif|jpg|png'; $config['allowed_types'] = 'gif|jpg|png|jpge';
$config['max_size'] = 20480; $config['max_size'] = 20480;
$config['max_width'] = 1024; $config['max_width'] = 1024;
$config['max_height'] = 768; $config['max_height'] = 768;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment