[eluser]Deathcode[/eluser]
hello everybody,
i have a problem saving data into database but i don't know why this is happen???
i have a textarea (tinymce), when i type something in there it's work fine(i can save the data) but when i copy paste article, that data can be save but it's empty. what is the problem???
FYI : i use textarea(tinymce) and then saved that data into session to preview (if there is no problem) and submit it into database, but before that data insert to the database i'll check data in session but my data is blank.
this is my code :
Code:
$data = array(
'filename' => $filename,
'company' => $this->input->post('company'),
'url' => $this->input->post('url'),
'userfile' => $logo,
'email' => $this->input->post('email'),
'jobtype' => $this->input->post('jobtype'),
'jobcategory' => $this->input->post('jobcategory'),
'location' => $this->input->post('location'),
'occupation' => $this->input->post('occupation'),
'description' =>$this->input->post('description'),
'jobperks' => $this->input->post('jobperks'),
'howtoapply' => $this->input->post('howtoapply')
);
$this->session->set_userdata($data);
this is my session setting :
Code:
$config['sess_cookie_name'] = 'ci_session';
$config['sess_expiration'] = 7200;
$config['sess_encrypt_cookie'] = TRUE;
$config['sess_use_database'] = FALSE;
$config['sess_table_name'] = 'ci_sessions';
$config['sess_match_ip'] = FALSE;
$config['sess_match_useragent'] = TRUE;
$config['sess_time_to_update'] = 300;
this is my setting init tinymce :
Code:
tinyMCE.init({
mode : "exact",
forced_root_block : false,
init_instance_callback : "myCustomInitInstance",
elements: "mce_tiny1",
force_p_newlines : false,
force_br_newlines : true,
theme : "advanced",
theme_advanced_buttons1: "bold,italic,underline, strikethrough, separator,justifyleft, justifycenter,justifyright, justifyfull, separator,bullist,numlist,link,unlink",
theme_advanced_buttons2: "",
theme_advanced_buttons3: "",
theme_advanced_buttons4: "",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
});