• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
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


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.