Welcome Guest, Not a member yet? Register   Sign In
Extend MY_Form_validation not work
#1

Hi,
I need help please, I dont' know why my method not works when I put it in the MY_Form_validation file.

I have that who it works for me : 

PHP Code:
function article_new()
{    
    
//Variable de configuration
 
   $allowed_types 'jpg|jpeg|png';
 
   $max_size     ='2048000';// 2 Mo
 
   $max_filename  '';//Pas besoin puisque le nom est cover
 
   
    $this
->form_validation
        
->set_rules('titre','Titre','trim|required|xss_clean|encode_php_tags')
        ->
set_rules('image','Image','callback_handle_upload['.$allowed_types.','.$max_size.','.$max_filename.']')
        ->
set_rules('tags','Tags','trim|required|xss_clean|encode_php_tags')
        ->
set_rules('article','Article','trim|required|xss_clean|encode_php_tags');
    
    if(
$this->form_validation->run() == FALSE)
    {

Reply




Theme © iAndrew 2016 - Forum software by © MyBB