CodeIgniter Forums

Full Version: How can i get the ckeditor value in $_POST?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

[eluser]Mistry007[/eluser]
Hi i am having trouble while using ckeditor. some how i cant get the value of editor in my $_post method
here are my code..

$this->load->helper('ckeditor');
//Ckeditor's configuration
$this->data['ckeditor'] = array(

//ID of the textarea that will be replaced
'id' => 'txt_customer_notes',
'path' => 'ckeditor',
'value' => $_POST['txt_customer_notes'],

//Optionnal values
'config' => array(
'toolbar' => "Basic", //Using the Full toolbar
'width' => "350px", //Setting a custom width
'height' => '100px', //Setting a custom height

),
//Replacing styles from the "Styles tool"
'styles' => array(

//Creating a new style named "style 1"
'style 1' => array (
'name' => 'Blue Title',
'element' => 'h2',
'styles' => array(
'color' => 'Blue',
'font-weight' => 'bold'
)
),

//Creating a new style named "style 2"
'style 2' => array (
'name' => 'Red Title',
'element' => 'h2',
'styles' => array(
'color' => 'Red',
'font-weight' => 'bold',
'text-decoration' => 'underline'
)
)
)
);

and here are my view file code

<input type='text' id='txt_customer_notes' name='txt_customer_notes' class=' txt_customer_notes'/>
<?php echo display_ckeditor($ckeditor); ?>

The ckeditor works fine but i cant get the txt_customer_notes value in my post method.
Can any one help me..... Smile
Thanks.