Ignore:
Timestamp:
Nov 1, 2010, 10:25:51 AM (13 years ago)
Author:
cljosse
Message:

[Autosize][beta] save.

File:
1 edited

Legend:

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

    r7394 r7536  
    2020// | USA.                                                                  |
    2121// +-----------------------------------------------------------------------+
    22 if (!defined('AUTOSIZE_PATH'))
    23 define('AUTOSIZE_PATH' , PHPWG_PLUGINS_PATH . basename(dirname(__FILE__)) . '/');
     22if (!defined('AUTOSIZE_PATH'))
     23define(
     24  'AUTOSIZE_PATH',
     25   PHPWG_PLUGINS_PATH.basename(dirname(__FILE__)).'/'
     26);
    2427
    2528class autosize_controler {
     
    3639                load_language('lang', AUTOSIZE_PATH);
    3740                $my_path = dirname(__FILE__).'/';
     41
    3842                if (isset( $page['body_id'])  ) {
    3943                if ( $page['body_id']=='thePicturePage'  ) {
     
    4145                               
    4246                                $autosize_parametres = cl_autosize_Get_Options();
    43                                 include (AUTOSIZE_PATH."include/affiche.php");   
     47                                include (AUTOSIZE_PATH."include/affiche.php"); 
     48                                $debug = isset($conf['debug']) ? $conf['debug'] : false ;
     49                                $cl_visible=isset($conf['cl_auto']) ? $conf['cl_auto'] : 'true' ;
     50                               
    4451                                if($autosize_parametres->check_icon_v == 'on'){
     52                                 
    4553                                $template->assign('cl_autosize_button',
    46                                  array(
     54                                 array( 
    4755                                                'cl_autosize_info' => 'cl_autosize_info' ,
    4856                                                'cl_autosize_info_2' => 'cl_autosize_info_2' ,   
     
    5159                                                'ICON' => AUTOSIZE_PATH . 'icons/button-minimize.png'
    5260                                        )
     61
    5362                                        );
    5463 
     
    5665                                $template->concat('PLUGIN_PICTURE_ACTIONS', $template->parse('cl_bp', true));
    5766                                }
     67                                 
     68
    5869                                $template->set_filenames(
    5970                                                array('autosize_content'=> $my_path.'template/autosize.tpl')
    6071                                        );
    61                                        
     72                   $template->assign(
     73                                                array('DEBUG' => $debug   ,
     74                                                'cl_visible' =>  $cl_visible
     75                                                )
     76                                                 );             
     77                                                                       
    6278                                return $template->parse( 'autosize_content', false);
    6379                        }
     
    117133        {
    118134           global  $template,$user,$conf ;
    119 
    120  
    121                 $my_path = dirname(__FILE__).'/';
     135 
     136                 
     137
     138                $my_path =  basename(dirname(__FILE__)).'/' ;
     139        $my_path = dirname(__FILE__).'/';
    122140                $template->set_filenames(
    123                      array('autosize_cl_init'=> $my_path.'template/cl_conflit.tpl')
    124                       );
    125                  
     141                     array('autosize_init'=>$my_path. "template/conflit.tpl" 
     142                         )
     143                      );                 
    126144                $template->assign(
    127                                                 array(
    128                                                 'AUTOSIZE_PATH' => $my_path,
    129 
    130                                                                                         )
     145                                                array('AUTOSIZE_ROOT' => AUTOSIZE_PATH)
    131146                                                 );
    132147
    133                    return $template->parse( 'autosize_cl_init', false);
     148                   return $template->parse( 'autosize_init', false);
    134149
    135150       
     
    141156 
    142157           global  $template,$user,$conf ;
    143                         $my_path = dirname(__FILE__).'/';
     158                        $my_path = realpath(AUTOSIZE_PATH .'/');
     159                       
    144160                        $template->set_filenames(
    145                      array('autosize_cl_init'=> $my_path.'template/cl_conflit.tpl')
     161                     array('autosize_cl_init'=> $my_path.'template/conflit.tpl')
    146162                      );
    147163 /*
Note: See TracChangeset for help on using the changeset viewer.