web/CPV/common.php
changeset 248 ffb0a6d08000
parent 247 e6b328970ee8
parent 239 66ac54f9dbf6
child 249 b31aef9365a8
equal deleted inserted replaced
247:e6b328970ee8 248:ffb0a6d08000
     1 <?php
       
     2 
       
     3 /**
       
     4  * If you haven't edited php.ini to add the Zend Framework and the
       
     5  * Zend Framework Incubator to the PHP include_path, then do so here.
       
     6  * Don't use mine!
       
     7  */
       
     8 set_include_path(
       
     9     'lib'
       
    10     . PATH_SEPARATOR . get_include_path()
       
    11 );
       
    12 
       
    13 
       
    14 include_once dirname(__FILE__).'/../traduction.php';
       
    15 include_once dirname(__FILE__).'/traduction.php';
       
    16 
       
    17 
       
    18 /**
       
    19  * Make sure Zend_Oauth's Consumer is loaded
       
    20  */
       
    21 require_once dirname(__FILE__).'/../lib/Zend/Oauth/Consumer.php';
       
    22 
       
    23 /** Zend_Locale */
       
    24 require_once dirname(__FILE__).'/../lib/Zend/Locale.php';
       
    25  
       
    26 /** Zend_Translate_Adapter */
       
    27 require_once dirname(__FILE__).'/../lib/Zend/Translate/Adapter.php';
       
    28 
       
    29 /**
       
    30  * Start up the ol' session engine
       
    31  */
       
    32 session_start();
       
    33 
       
    34 /**
       
    35  * Include the configuration data for our OAuth Client (array $configuration)
       
    36  */
       
    37 include_once dirname(__FILE__).'/config.php';
       
    38 
       
    39 /**
       
    40  * Setup an instance of the Consumer for use
       
    41  */
       
    42 $consumer = new Zend_Oauth_Consumer($configuration);
       
    43 
       
    44 /**
       
    45  * TRADUCTION
       
    46 **/
       
    47 
       
    48 
       
    49 Zend_Loader::loadClass('Zend_Translate'); 
       
    50 Zend_Loader::loadClass('Zend_Http_Cookie'); 
       
    51 
       
    52 
       
    53 $client = new Zend_Http_Client();
       
    54 $translate = new Zend_Translate('array', $init, 'fr');
       
    55 
       
    56 $translate->addTranslation($english, 'en');
       
    57 $translate->addTranslation($japan, 'ja_JP');
       
    58 $translate->addTranslation($french, 'fr');
       
    59 
       
    60 $actual = $translate->getLocale();
       
    61 
       
    62 //$translate->setLocale("en");
       
    63 // $acceptCookie = $this->_request->getCookie('acceptCookie',0);
       
    64 
       
    65 if(isset($_GET['lang'])==false and isset($_SESSION['lang'])==false){
       
    66 	
       
    67 	if($actual!='fr' and $actual!='en' and $actual!='ja_JP'){
       
    68 		$translate->setLocale("fr");
       
    69 		 $_SESSION['lang']="fr";
       
    70 	}
       
    71 	
       
    72 } else if (isset($_GET['lang'])==true){
       
    73 	$translate->setLocale($_GET['lang']);
       
    74     $_SESSION['lang'] = $_GET['lang'];
       
    75     $actual = $_SESSION['lang'];
       
    76 
       
    77 } else if (isset($_SESSION['lang'])==true){
       
    78 	$translate->setLocale( $_SESSION['lang']);
       
    79     $actual = $_SESSION['lang'];
       
    80 	
       
    81 }
       
    82 
       
    83 /* NEXT CONFERENCE AND CLIENT PAGE INFORMATION
       
    84 */
       
    85 /* CLIENT VAR LIVE */
       
    86 
       
    87 $C_hashtag = "#SNCP";
       
    88 $C_link  = "http://www.iri.centrepompidou.fr/evenement/atelier-preparatoire-aux-entretiens-du-nouveau-monde-industriel-technologies-de-la-confiance/";
       
    89 $C_title = "Les Stratégies Virtuelles des Musées&nbsp;: l'Heure de Vérité";
       
    90 $C_abstract = "Les Stratégies Virtuelles des Musées&nbsp;: l'Heure de Vérité";
       
    91 $C_REP   = "CPV/";
       
    92 $C_description  = "<h3>JEUDI 26 MAI 2011</h3><br />
       
    93 <h4>DE 10H A 13H<br />
       
    94 PETITE SALLE, NIVEAU -1</h4><br />
       
    95 Intervenants&nbsp;:<br />
       
    96 <b>Carlo d'Asaro Biondo</b>, vice-président de Google<br/>
       
    97 <b>Franck Riester</b>, député de Seine-et-Marne<br/>
       
    98 <b>Marc Sands</b>, directeur des publics et de l'information, Tate Gallery, Londres<br/>
       
    99 <b>Alain Seban</b>, président du Centre Pompidou<br/>
       
   100 <b>Bernard Stiegler</b>, philosophe et directeur de l'Institut de Recherche et d'Innovation (IRI)<br /><br />
       
   101 Animée par <b>Brice Couturier</b>, écrivain et producteur à France Culture<br /><br />
       
   102 La table ronde sera suivie d'un déjeuner-buffet<br /><br /><br />
       
   103 RSVP: <b>rp@centrepompidou.fr</b> ou <b>01 44 78 15 05</b>";
       
   104 
       
   105 $C_partenaires = "<a href='http://www.iri.centrepompidou.fr/' class='footerLink' target='_blank'> IRI </a>
       
   106 		 |  <a href='http://www.centrepompidou.fr/' class='footerLink' target='_blank' > Centre Pompidou  </a>";
       
   107 
       
   108