web/polemicaltimeline.php
changeset 291 db1e6bfaa54e
parent 276 f7669b499d41
child 292 dfcc0e08f295
equal deleted inserted replaced
290:2ddd11ec2da2 291:db1e6bfaa54e
     4  * include some common code (like we did in the 90s)
     4  * include some common code (like we did in the 90s)
     5  * People still do this? ;)
     5  * People still do this? ;)
     6  */
     6  */
     7 $rep = $_REQUEST['rep'];
     7 $rep = $_REQUEST['rep'];
     8 include_once dirname(__FILE__).'/'.$rep.'/config.php';
     8 include_once dirname(__FILE__).'/'.$rep.'/config.php';
     9 // configuration 
     9 // configuration
    10 include 'common.php';
    10 include 'common.php';
    11  // objet actuel 
    11  // objet actuel
    12 $baseurl = URL_ROOT;
    12 $baseurl = URL_ROOT;
    13 
    13 
    14 $div_height = 640;
    14 $div_height = 640;
    15 if(isset($config['div_height'])) {
    15 if($translate->_('config__div_height') != 'config__div_height') {
    16 	$div_height = $config['div_height'];	
    16 	$div_height = $translate->_('config__div_height');
    17 }
    17 }
    18 $tweet_explain_background = URL_ROOT.'images/tweetExplainBgd.gif';
    18 $tweet_explain_background = URL_ROOT.'images/tweetExplainBgd.gif';
    19 if(file_exists(dirname(__FILE__)."/$rep/images/tweetExplainBgd.gif")) {
    19 if(file_exists(dirname(__FILE__)."/$rep/images/tweetExplainBgd.gif")) {
    20 	$tweet_explain_background = URL_ROOT.$rep.'/images/tweetExplainBgd.gif';
    20 	$tweet_explain_background = URL_ROOT.$rep.'/images/tweetExplainBgd.gif';
    21 }
    21 }
    26 ?>
    26 ?>
    27 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
    27 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
    28 <html lang="<?php echo($actual); ?>">
    28 <html lang="<?php echo($actual); ?>">
    29   <head>
    29   <head>
    30     <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    30     <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    31     <title>Polemic tweet - <?php echo($config['title']); ?></title>
    31     <title>Polemic tweet - <?php echo($translate->_('config__title')); ?></title>
    32 	<meta name="keywords" content="<?php echo($config['keywords']); ?>"><!-- add timestampedmetadata -->
    32 	<meta name="keywords" content="<?php echo($translate->_('config__keywords')); ?>"><!-- add timestampedmetadata -->
    33 	<!--<meta name="description" content="PoelmicTweet.fr : debate mapping, opinion, conference, video">-->
    33 	<!--<meta name="description" content="PoelmicTweet.fr : debate mapping, opinion, conference, video">-->
    34 	<meta name="description" content="<?php echo($config['description']); ?>">
    34 	<meta name="description" content="<?php echo($translate->_('config__description')); ?>">
    35 	<meta name="robots" content="index, follow">
    35 	<meta name="robots" content="index, follow">
    36 	
    36 	
    37 	<!-- ICI : <?php echo($_SERVER['DOCUMENT_ROOT']); ?> -->
    37 	<!-- ICI : <?php echo($_SERVER['DOCUMENT_ROOT']); ?> -->
    38 	<!-- JAVASCRIPT --> 
    38 	<!-- JAVASCRIPT -->
    39 	<script type="text/javascript" src="<?php echo(registry_url('json-js','js'));?>"></script>
    39 	<script type="text/javascript" src="<?php echo(registry_url('json-js','js'));?>"></script>
    40 	<script type="text/javascript" src="<?php echo(registry_url('jquery','js'));?>"></script>
    40 	<script type="text/javascript" src="<?php echo(registry_url('jquery','js'));?>"></script>
    41 	<script type="text/javascript">	
    41 	<script type="text/javascript">
    42 		$.noConflict();
    42 		$.noConflict();
    43 	</script>
    43 	</script>
    44 	<script type="text/javascript" src="<?php echo(registry_url('raphael','js'));?>"></script>
    44 	<script type="text/javascript" src="<?php echo(registry_url('raphael','js'));?>"></script>
    45 	<script type="text/javascript" src="<?php echo(registry_url('fancybox','js'));?>"></script>
    45 	<script type="text/javascript" src="<?php echo(registry_url('fancybox','js'));?>"></script>
    46 	<script type="text/javascript" src="<?php echo(registry_url('jquery-url','js'));?>"></script>
    46 	<script type="text/javascript" src="<?php echo(registry_url('jquery-url','js'));?>"></script>
    47 	<script type="text/javascript" src="<?php echo(registry_url('ldtplayer','js'));?>"></script>
    47 	<script type="text/javascript" src="<?php echo(registry_url('ldtplayer','js'));?>"></script>
    48 		
    48 		
    49 	<!-- Framework CSS -->
    49 	<!-- Framework CSS -->
    50     <link rel="stylesheet" href="<?php echo(registry_url('blueprint-screen','css'));?>" type="text/css" media="screen, projection"/>
    50     <link rel="stylesheet" href="<?php echo(registry_url('blueprint-screen','css'));?>" type="text/css" media="screen, projection"/>
    51     <link rel="stylesheet" href="<?php echo(registry_url('blueprint-print','css'));?>" type="text/css" media="print"/>
    51     <link rel="stylesheet" href="<?php echo(registry_url('blueprint-print','css'));?>" type="text/css" media="print"/>
    52     <!--[if lt IE 8]><link rel="stylesheet" href="<?php echo(registry_url('blueprint-ie','css'));?>" type="text/css" media="screen, projection"><![endif]--> 
    52     <!--[if lt IE 8]><link rel="stylesheet" href="<?php echo(registry_url('blueprint-ie','css'));?>" type="text/css" media="screen, projection"><![endif]-->
    53 	<link rel="stylesheet" href="<?php echo(registry_url('blueprint-plugins-fancy-type','css'));?>" type="text/css" media="screen, projection"/>
    53 	<link rel="stylesheet" href="<?php echo(registry_url('blueprint-plugins-fancy-type','css'));?>" type="text/css" media="screen, projection"/>
    54 	<link rel="stylesheet" href="<?php echo(registry_url('custom','css'));?>" type="text/css" media="screen, projection"/>
    54 	<link rel="stylesheet" href="<?php echo(registry_url('custom','css'));?>" type="text/css" media="screen, projection"/>
    55 	<link rel="stylesheet" href="<?php echo(registry_url('fancybox','css'));?>" media="screen"/>
    55 	<link rel="stylesheet" href="<?php echo(registry_url('fancybox','css'));?>" media="screen"/>
    56 	
    56 	
    57 	<!-- FONT -->
    57 	<!-- FONT -->
    58 	<link href='<?php echo(registry_url('PT-Sans_Narrow','font'));?>' rel='stylesheet' type='text/css'/>
    58 	<link href='<?php echo(registry_url('PT-Sans_Narrow','font'));?>' rel='stylesheet' type='text/css'/>
    59 	<link href='<?php echo(registry_url('PT-Sans','font'));?>' rel='stylesheet' type='text/css'/>
    59 	<link href='<?php echo(registry_url('PT-Sans','font'));?>' rel='stylesheet' type='text/css'/>
    60 	<link href='<?php echo(registry_url('Geo','font'));?>' rel='stylesheet' type='text/css'/>
    60 	<link href='<?php echo(registry_url('Geo','font'));?>' rel='stylesheet' type='text/css'/>
    61 	
    61 	
    62 	<style type="text/css"> 
    62 	<style type="text/css">
    63 		.tweetButton{float:left;margin-right:5px;}
    63 		.tweetButton{float:left;margin-right:5px;}
    64 		.videoLivePlayer{border:1px solid #c3c3c3;width:650px;height:<?php echo($div_height-2);?>px;}
    64 		.videoLivePlayer{border:1px solid #c3c3c3;width:650px;height:<?php echo($div_height-2);?>px;}
    65 		.videoLive{width:650px;height:<?php echo($div_height); ?>px;background:#fff;float:right;margin-top:20px;padding:5px;}					
    65 		.videoLive{width:650px;height:<?php echo($div_height); ?>px;background:#fff;float:right;margin-top:20px;padding:5px;}
    66 		.tweetExplain{background-image:url(<?php echo($tweet_explain_background);?>);width:250px;height:<?php echo($div_height)?>px;padding:10px;position:absolute; margin-top:70px;}
    66 		.tweetExplain{background-image:url(<?php echo($tweet_explain_background);?>);width:250px;height:<?php echo($div_height)?>px;padding:10px;position:absolute; margin-top:70px;}
    67 		.footer{margin-top:<?php echo($div_height+100);?>px;width:960px;height:20px;position:absolute;text-align:center;}
    67 		.footer{margin-top:<?php echo($div_height+100);?>px;width:960px;height:20px;position:absolute;text-align:center;}
    68 		.tooltip{
    68 		.tooltip{
    69 			 z-index: 10000000000;
    69 			 z-index: 10000000000;
    70 		}
    70 		}
    71 		#tip{
    71 		#tip{
    72 			 position : absolute;
    72 			 position : absolute;
    73 			 padding : 3px;
    73 			 padding : 3px;
    74 			 z-index: 10000000000;
    74 			 z-index: 10000000000;
    75 			 max-width: 200px;
    75 			 max-width: 200px;
    76 		}	
    76 		}
    77 		#tip {
    77 		#tip {
    78 				display: none;
    78 				display: none;
    79 				background: transparent url("<?php echo($baseurl);?>images/white_arrow_long.png");
    79 				background: transparent url("<?php echo($baseurl);?>images/white_arrow_long.png");
    80 				font-size: 12px;
    80 				font-size: 12px;
    81 				height: 125px;
    81 				height: 125px;
    93 			padding-top: 0px;
    93 			padding-top: 0px;
    94 			z-index: 9;
    94 			z-index: 9;
    95 			position : absolute;
    95 			position : absolute;
    96 		}
    96 		}
    97 
    97 
    98 	</style>	
    98 	</style>
    99 	<script type="text/javascript">
    99 	<script type="text/javascript">
   100   		// Configuration Polemical Timeline
   100   		// Configuration Polemical Timeline
   101   		<?php
   101   		<?php
   102   		if(is_array($config['metadata'])):
   102   		if(is_array($translate->_('config__metadata'))):
   103   			reset($config['metadata']);
   103   			reset($translate->_('config__metadata'));
   104   		    $first_key = key($config['metadata']);
   104   		    $first_key = key($translate->_('config__metadata'));
   105   		?>
   105   		?>
   106   		var metadatas = jQuery.parseJSON('<?php echo(json_encode($config['metadata'])); ?>');
   106   		var metadatas = jQuery.parseJSON('<?php echo(json_encode($translate->_('config__metadata'))); ?>');
   107   		var url = jQuery.url();
   107   		var url = jQuery.url();
   108   		var metadata_key = url.fparam('metadata');
   108   		var metadata_key = url.fparam('metadata');
   109   		if(typeof metadata_key === "undefined" || metadata_key.length === 0) {
   109   		if(typeof metadata_key === "undefined" || metadata_key.length === 0) {
   110   			metadata_key = "<?php echo($first_key);?>";
   110   			metadata_key = "<?php echo($first_key);?>";
   111   		} 
   111   		}
   112   		<?php else: ?>
   112   		<?php else: ?>
   113   		var metadatas = { metadata: {url: "<?php echo($config['metadata']);?>", duration: <?php echo($config['duration'])?>} };
   113   		var metadatas = { metadata: {url: "<?php echo($translate->_('config__metadata'));?>", duration: <?php echo($translate->_('config__duration'))?>} };
   114   		var metadata_key = "metadata"; 
   114   		var metadata_key = "metadata";
   115   		<?php endif;?>
   115   		<?php endif;?>
   116   		
   116   		
   117 		var config = {
   117 		var config = {
   118 					target:"chartTimeline",
   118 					target:"chartTimeline",
   119 					x:8,
   119 					x:8,
   120 					y:418,
   120 					y:418,
   121 					width:<?php echo($config['player_width']); ?>,
   121 					width:<?php echo($translate->_('config__player_width')); ?>,
   122 					height:<?php echo($config['player_height']); ?>,
   122 					height:<?php echo($translate->_('config__player_height')); ?>,
   123 					heightmax:<?php echo($config['player_height']); ?>,
   123 					heightmax:<?php echo($translate->_('config__player_height')); ?>,
   124 					duration:metadatas[metadata_key].duration,
   124 					duration:metadatas[metadata_key].duration,
   125 					metadata:metadatas[metadata_key].url
   125 					metadata:metadatas[metadata_key].url
   126 					};
   126 					};
   127   	</script>
   127   	</script>
   128 	<script type='text/javascript' src='<?php echo(URL_ROOT);?>res/metadataplayer.polemic/src/js/polemic.js'></script>
   128 	<script type='text/javascript' src='<?php echo(URL_ROOT);?>res/metadataplayer.polemic/src/js/polemic.js'></script>
   129 	<script type="text/javascript">
   129 	<script type="text/javascript">
   130 		jQuery.extend(__IriSP.lib,{
   130 		jQuery.extend(__IriSP.lib,{
   131 			jQueryToolTip:"<?php echo(registry_url('jquery-tools','js'));?>",
   131 			jQueryToolTip:"<?php echo(registry_url('jquery-tools','js'));?>",
   132 			jQueryUI:"<?php echo(registry_url('jquery-ui','js'));?>",
   132 			jQueryUI:"<?php echo(registry_url('jquery-ui','js'));?>",
   133 			swfObject:"<?php echo(registry_url('swfobject','js'));?>",
   133 			swfObject:"<?php echo(registry_url('swfobject','js'));?>",
   134 			cssjQueryUI:"<?php echo(registry_url('jquery-ui','css'));?>"			
   134 			cssjQueryUI:"<?php echo(registry_url('jquery-ui','css'));?>"
   135 		});
   135 		});
   136 		jQuery(document).ready(function() {
   136 		jQuery(document).ready(function() {
   137 			
   137 			
   138 			jQuery("#mdselect_"+metadata_key).attr("selected","selected");
   138 			jQuery("#mdselect_"+metadata_key).attr("selected","selected");
   139 			jQuery("#mdselect").change(function() {
   139 			jQuery("#mdselect").change(function() {
   154 				'transitionOut'		: 'none',
   154 				'transitionOut'		: 'none',
   155 				'type'				: 'iframe'
   155 				'type'				: 'iframe'
   156 			});
   156 			});
   157 			
   157 			
   158 		});
   158 		});
   159 	</script>	
   159 	</script>
   160 	<script type="text/javascript">
   160 	<script type="text/javascript">
   161 		var _gaq = _gaq || [];
   161 		var _gaq = _gaq || [];
   162 		_gaq.push(['_setAccount', 'UA-23581291-1']);
   162 		_gaq.push(['_setAccount', 'UA-23581291-1']);
   163 		_gaq.push(['_trackPageview']);
   163 		_gaq.push(['_trackPageview']);
   164 		_gaq.push(['_setAllowAnchor', true]); 
   164 		_gaq.push(['_setAllowAnchor', true]);
   165 	  
   165 	  
   166 		(function() {
   166 		(function() {
   167 		    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
   167 		    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
   168 		    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
   168 		    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
   169 		    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
   169 		    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
   171 	</script>
   171 	</script>
   172   </head>
   172   </head>
   173   <body>
   173   <body>
   174   <div id="sendUsFeedBack"><a href="<?php echo($C_feedback_form_url); ?>" target="_blank"><img src="<?php echo(URL_ROOT); ?>images/sendusfeedback.png"></a></div>
   174   <div id="sendUsFeedBack"><a href="<?php echo($C_feedback_form_url); ?>" target="_blank"><img src="<?php echo(URL_ROOT); ?>images/sendusfeedback.png"></a></div>
   175 
   175 
   176   <!-- tooltip --> 
   176   <!-- tooltip -->
   177   <div id="tip">
   177   <div id="tip">
   178   <div id="tipcolor" style="height:10px;width:10px"></div>
   178   <div id="tipcolor" style="height:10px;width:10px"></div>
   179   <div id="tiptext"></div>
   179   <div id="tiptext"></div>
   180   </div>
   180   </div>
   181 
   181 
   182     <div class="container">
   182     <div class="container">
   183       <img src="<?php echo(URL_ROOT."$rep/$config[head_logo]");?>" class="logo">
   183       <img src="<?php echo(URL_ROOT."$rep/$config[head_logo]");?>" class="logo">
   184       <div id="minilogo" style="margin-left:85px;height:5px;top:5px;"></div>
   184       <div id="minilogo" style="margin-left:85px;height:5px;top:5px;"></div>
   185 	  <ul class="menu"> 
   185 	  <ul class="menu">
   186 		  <li class="menuUnderline"><a href="<?php echo(URL_ROOT)?>" class="menuLink" id="Accueil">
   186 		  <li class="menuUnderline"><a href="<?php echo(URL_ROOT)?>" class="menuLink" id="Accueil">
   187 		   <?php print $translate->_("Accueil"); ?></a></li>
   187 		   <?php print $translate->_("Accueil"); ?></a></li>
   188 		  <li class="menuUnderline"><a href="<?php echo(URL_ROOT.$rep)?>/embed_form.php" class="menuLink" id="Embeded">
   188 		  <li class="menuUnderline"><a href="<?php echo(URL_ROOT.$rep)?>/embed_form.php" class="menuLink" id="Embeded">
   189 		    <?php print $translate->_("Partager"); ?></a></li>
   189 		    <?php print $translate->_("Partager"); ?></a></li>
   190 		  <li >&nbsp;</li>
   190 		  <li >&nbsp;</li>
   192 	  <ul class="menu">
   192 	  <ul class="menu">
   193 	  <li class="menuUnderline"><a href="<?php echo(URL_ROOT); ?>archives.php" class="menuLink">
   193 	  <li class="menuUnderline"><a href="<?php echo(URL_ROOT); ?>archives.php" class="menuLink">
   194 	  <?php print $translate->_("Archives"); ?></a></li>
   194 	  <?php print $translate->_("Archives"); ?></a></li>
   195 	  </ul>
   195 	  </ul>
   196 	  	  
   196 	  	  
   197 	<?php if(is_array($config['metadata'])): ?>
   197 	<?php if(is_array($translate->_('config__metadata'))): ?>
   198 	<ul id="content_select_ul" class="menu mdselect">
   198 	<ul id="content_select_ul" class="menu mdselect">
   199 	    <span><?php print $translate->_("changer de contenu"); ?></span><br/>
   199 	    <span><?php print $translate->_("changer de contenu"); ?></span><br/>
   200 	    <select id="mdselect">
   200 	    <select id="mdselect">
   201 	    	<?php foreach ($config['metadata'] as $key => $value):?>
   201 	    	<?php foreach ($translate->_('config__metadata') as $key => $value):?>
   202 	    	<option value="<?php echo($key); ?>" id="mdselect_<?php echo($key); ?>" ><?php echo($value['display']); ?></option>
   202 	    	<option value="<?php echo($key); ?>" id="mdselect_<?php echo($key); ?>" ><?php echo($value['display']); ?></option>
   203 	    	<?php endforeach;?>
   203 	    	<?php endforeach;?>
   204 	    </select>
   204 	    </select>
   205 	</ul>
   205 	</ul>
   206 	<ul class="menu shortlang" >
   206 	<ul class="menu shortlang" >
   207 	<?php else: ?>
   207 	<?php else: ?>
   208 	<ul class="menu lang" >
   208 	<ul class="menu lang" >
   209 	<?php endif;?>	  
   209 	<?php endif;?>
   210 	  <li class="menuUnderline"><a href="<?php echo(URL_ROOT.$rep);?>/polemicaltimeline.php?lang=ja_JP" class="menuLink" >
   210 	  <li class="menuUnderline"><a href="<?php echo(URL_ROOT.$rep);?>/polemicaltimeline.php?lang=ja_JP" class="menuLink" >
   211 	       <img src="<?php echo(URL_ROOT)?>images/flag_jp.gif"<?php if($actual!="ja_JP"){echo("style='opacity: .5;'"); } ?> />
   211 	       <img src="<?php echo(URL_ROOT)?>images/flag_jp.gif"<?php if($actual!="ja_JP"){echo("style='opacity: .5;'"); } ?> />
   212 	        <?php print $translate->_("Japonais"); ?></a></li>
   212 	        <?php print $translate->_("Japonais"); ?></a></li>
   213 	  <li class="menuUnderline"><a href="<?php echo(URL_ROOT.$rep) ?>/polemicaltimeline.php?lang=fr" class="menuLink">
   213 	  <li class="menuUnderline"><a href="<?php echo(URL_ROOT.$rep) ?>/polemicaltimeline.php?lang=fr" class="menuLink">
   214 	       <img src="<?php echo(URL_ROOT)?>images/flag_fr.gif" <?php if($actual!="fr"){echo("style='opacity: .5;'"); } ?> />
   214 	       <img src="<?php echo(URL_ROOT)?>images/flag_fr.gif" <?php if($actual!="fr"){echo("style='opacity: .5;'"); } ?> />
   215 	       <?php print $translate->_("Français"); ?></a></li>
   215 	       <?php print $translate->_("Français"); ?></a></li>
   216 	  <li ><a href="<?php echo(URL_ROOT.$rep) ?>/polemicaltimeline.php?lang=en" class="menuLink">
   216 	  <li ><a href="<?php echo(URL_ROOT.$rep) ?>/polemicaltimeline.php?lang=en" class="menuLink">
   217 	       <img src="<?php echo(URL_ROOT)?>images/flag_en.gif" <?php if($actual!="en"){echo("style='opacity: .5;'"); } ?> />
   217 	       <img src="<?php echo(URL_ROOT)?>images/flag_en.gif" <?php if($actual!="en"){echo("style='opacity: .5;'"); } ?> />
   218 	       <?php print $translate->_("Anglais"); ?></a></li>
   218 	       <?php print $translate->_("Anglais"); ?></a></li>
   219 	  </ul>	
   219 	  </ul>
   220 	
   220 	
   221 	<!-- EXPLICATION  -->
   221 	<!-- EXPLICATION  -->
   222 	  <div class="tweetExplain"  >
   222 	  <div class="tweetExplain"  >
   223 		<h3 class="tweetWriterTitle"><?php print $translate->_("ClientTitle1 :"); ?> </h3><br/>
   223 		<h3 class="tweetWriterTitle"><?php print $translate->_("ClientTitle1 :"); ?> </h3><br/>
   224 		<?php print $translate->_("ExplicationPT"); ?>
   224 		<?php print $translate->_("ExplicationPT"); ?>
   225 	  </div>
   225 	  </div>
   226 	 
   226 	 
   227 	  
   227 	  
   228 	  <!-- INFOS SUR LA CONF 
   228 	  <!-- INFOS SUR LA CONF
   229 	  	<div class="tweetExplain"  >
   229 	  	<div class="tweetExplain"  >
   230 		<h3 class="tweetWriterTitle"><?php echo($config['title']); ?></h3><br/>
   230 		<h3 class="tweetWriterTitle"><?php echo($translate->_('config__title')); ?></h3><br/>
   231 			<?php echo($config['description']); ?>
   231 			<?php echo($translate->_('config__description')); ?>
   232 	  </div>
   232 	  </div>
   233 	  -->
   233 	  -->
   234 
   234 
   235 
   235 
   236 
   236 
   266 	  </div>
   266 	  </div>
   267 
   267 
   268  
   268  
   269       <div class="footer">
   269       <div class="footer">
   270 		<hr>
   270 		<hr>
   271 			<?php echo($config['partenaires']); ?>
   271 			<?php echo($translate->_('config__partenaires')); ?>
   272 	  </div>   
   272 	  </div>
   273 	
   273 	
   274     </div>
   274     </div>
   275 
   275 
   276   </body>
   276   </body>
   277 </html>
   277 </html>