Ignore:
Timestamp:
Nov 17, 2010, 5:04:11 PM (13 years ago)
Author:
cljosse
Message:

[Autosize][beta] save

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/Autosize/autosize.inc.php

    r7741 r7805  
    131131 * conflit =============================================
    132132 */
    133  static public function cl_autosize_script_2($pictures)
     133 static public function cl_autosize_script_3()
    134134 {
    135            global  $template,$user,$conf,$picture ;
    136 
     135           global  $template,$user,$conf,$picture ,$page;
     136           //userDefManage ??
    137137                $my_path =  basename(dirname(__FILE__)).'/' ;
    138138            $my_path = dirname(__FILE__).'/';
    139                 $template->set_filenames(
     139                        $debug = isset($conf['debug']) ? $conf['debug'] : false ;
     140                        $cl_conflit =  isset($conf['cl_conflit']) ? $conf['cl_conflit'] : 'false' ;
     141                        $template->set_filenames(
     142                     array('autosize_init'=>$my_path. "template/cl_conflit3.tpl" 
     143                         )
     144                      );               
     145                         
     146                       
     147                          $theme=$user['theme'];
     148                         
     149                $template->assign(
     150                                                array(
     151                                                'cl_conflit' => $cl_conflit  ,
     152                                                'theme' => $theme  ,
     153                                                'DEBUG' => $debug   ,
     154                                                'AUTOSIZE_PATH' => AUTOSIZE_PATH)
     155                                                 );
     156
     157if(     $page['body_id'] == 'theAdminPage' ) return ;
     158
     159                   return $template->parse( 'autosize_init', false);
     160
     161 }// function cl_autosize_script_3
     162
     163 static public function cl_autosize_script_2()
     164 {
     165           global  $template,$user,$conf,$picture ,$page;
     166           //userDefManage ??
     167                $my_path =  basename(dirname(__FILE__)).'/' ;
     168            $my_path = dirname(__FILE__).'/';
     169                        $debug = isset($conf['debug']) ? $conf['debug'] : false ;
     170                        $cl_conflit =  isset($conf['cl_conflit']) ? $conf['cl_conflit'] : 'false' ;
     171                        $template->set_filenames(
    140172                     array('autosize_init'=>$my_path. "template/cl_conflit.tpl" 
    141173                         )
    142                       );                 
     174                      );               
     175                         
     176                       
     177                          $theme=$user['theme'];
     178                         
    143179                $template->assign(
    144                                                 array(
     180                                                array('ma_page' =>      $page['body_id'],
     181                                                'cl_conflit' => $cl_conflit  ,
     182                                                'theme' => $theme  ,
    145183                                                'DEBUG' => $debug   ,
    146                                                 'AUTOSIZE_ROOT' => AUTOSIZE_PATH)
     184                                                'AUTOSIZE_PATH' => AUTOSIZE_PATH)
    147185                                                 );
    148186
    149                  
    150                 return $pictures;
    151  }
     187if(     $page['body_id'] == 'theAdminPage' ) return ;
     188
     189                   return $template->parse( 'autosize_init', false);
     190
     191 }// function cl_autosize_script_2
    152192 //============================================================
    153193        static public function cl_autosize_script()
     
    158198            $my_path = dirname(__FILE__).'/';
    159199                        $debug = isset($conf['debug']) ? $conf['debug'] : false ;
    160                         $template->func_known_script(array('id'=>'jquery', 'src'=>get_root_url().'themes/default/js/jquery.packed.js'), $smarty);
    161                 $template->func_known_script(array('id'=>'jquery', 'src'=>$my_path. '/js/jconflit.js'), $smarty);
    162        
    163 
    164 
    165 
    166                 $template->set_filenames(
     200                        $cl_conflit =  isset($conf['cl_conflit']) ? $conf['cl_conflit'] : 'false' ;
     201                        $template->set_filenames(
    167202                     array('autosize_init'=>$my_path. "template/conflit.tpl" 
    168203                         )
    169                       );                 
     204                      );               
     205                         
     206                       
    170207                          $theme=$user['theme'];
     208                         
    171209                $template->assign(
    172                                                 array('theme' => $theme  ,
     210                                                array(
     211                                                'cl_conflit' => $cl_conflit  ,
     212                                                'theme' => $theme  ,
    173213                                                'DEBUG' => $debug   ,
    174                                                 'AUTOSIZE_ROOT' => AUTOSIZE_PATH)
     214                                                'AUTOSIZE_PATH' => AUTOSIZE_PATH)
    175215                                                 );
     216
    176217if(     $page['body_id'] == 'theAdminPage' ) return ;
     218
    177219                   return $template->parse( 'autosize_init', false);
    178220
     
    191233                        $data = array();
    192234                       
     235                         
    193236
    194237 return $content;
Note: See TracChangeset for help on using the changeset viewer.