--- a/web/polemicaltimeline.php Wed Oct 05 13:39:57 2011 +0200
+++ b/web/polemicaltimeline.php Wed Oct 05 18:11:31 2011 +0200
@@ -6,14 +6,14 @@
*/
$rep = $_REQUEST['rep'];
include_once dirname(__FILE__).'/'.$rep.'/config.php';
-// configuration
+// configuration
include 'common.php';
- // objet actuel
+ // objet actuel
$baseurl = URL_ROOT;
$div_height = 640;
-if(isset($config['div_height'])) {
- $div_height = $config['div_height'];
+if($translate->_('config__div_height') != 'config__div_height') {
+ $div_height = $translate->_('config__div_height');
}
$tweet_explain_background = URL_ROOT.'images/tweetExplainBgd.gif';
if(file_exists(dirname(__FILE__)."/$rep/images/tweetExplainBgd.gif")) {
@@ -28,17 +28,17 @@
<html lang="<?php echo($actual); ?>">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
- <title>Polemic tweet - <?php echo($config['title']); ?></title>
- <meta name="keywords" content="<?php echo($config['keywords']); ?>"><!-- add timestampedmetadata -->
+ <title>Polemic tweet - <?php echo($translate->_('config__title')); ?></title>
+ <meta name="keywords" content="<?php echo($translate->_('config__keywords')); ?>"><!-- add timestampedmetadata -->
<!--<meta name="description" content="PoelmicTweet.fr : debate mapping, opinion, conference, video">-->
- <meta name="description" content="<?php echo($config['description']); ?>">
+ <meta name="description" content="<?php echo($translate->_('config__description')); ?>">
<meta name="robots" content="index, follow">
<!-- ICI : <?php echo($_SERVER['DOCUMENT_ROOT']); ?> -->
- <!-- JAVASCRIPT -->
+ <!-- JAVASCRIPT -->
<script type="text/javascript" src="<?php echo(registry_url('json-js','js'));?>"></script>
<script type="text/javascript" src="<?php echo(registry_url('jquery','js'));?>"></script>
- <script type="text/javascript">
+ <script type="text/javascript">
$.noConflict();
</script>
<script type="text/javascript" src="<?php echo(registry_url('raphael','js'));?>"></script>
@@ -49,7 +49,7 @@
<!-- Framework CSS -->
<link rel="stylesheet" href="<?php echo(registry_url('blueprint-screen','css'));?>" type="text/css" media="screen, projection"/>
<link rel="stylesheet" href="<?php echo(registry_url('blueprint-print','css'));?>" type="text/css" media="print"/>
- <!--[if lt IE 8]><link rel="stylesheet" href="<?php echo(registry_url('blueprint-ie','css'));?>" type="text/css" media="screen, projection"><![endif]-->
+ <!--[if lt IE 8]><link rel="stylesheet" href="<?php echo(registry_url('blueprint-ie','css'));?>" type="text/css" media="screen, projection"><![endif]-->
<link rel="stylesheet" href="<?php echo(registry_url('blueprint-plugins-fancy-type','css'));?>" type="text/css" media="screen, projection"/>
<link rel="stylesheet" href="<?php echo(registry_url('custom','css'));?>" type="text/css" media="screen, projection"/>
<link rel="stylesheet" href="<?php echo(registry_url('fancybox','css'));?>" media="screen"/>
@@ -59,10 +59,10 @@
<link href='<?php echo(registry_url('PT-Sans','font'));?>' rel='stylesheet' type='text/css'/>
<link href='<?php echo(registry_url('Geo','font'));?>' rel='stylesheet' type='text/css'/>
- <style type="text/css">
+ <style type="text/css">
.tweetButton{float:left;margin-right:5px;}
.videoLivePlayer{border:1px solid #c3c3c3;width:650px;height:<?php echo($div_height-2);?>px;}
- .videoLive{width:650px;height:<?php echo($div_height); ?>px;background:#fff;float:right;margin-top:20px;padding:5px;}
+ .videoLive{width:650px;height:<?php echo($div_height); ?>px;background:#fff;float:right;margin-top:20px;padding:5px;}
.tweetExplain{background-image:url(<?php echo($tweet_explain_background);?>);width:250px;height:<?php echo($div_height)?>px;padding:10px;position:absolute; margin-top:70px;}
.footer{margin-top:<?php echo($div_height+100);?>px;width:960px;height:20px;position:absolute;text-align:center;}
.tooltip{
@@ -73,7 +73,7 @@
padding : 3px;
z-index: 10000000000;
max-width: 200px;
- }
+ }
#tip {
display: none;
background: transparent url("<?php echo($baseurl);?>images/white_arrow_long.png");
@@ -95,32 +95,32 @@
position : absolute;
}
- </style>
+ </style>
<script type="text/javascript">
// Configuration Polemical Timeline
<?php
- if(is_array($config['metadata'])):
- reset($config['metadata']);
- $first_key = key($config['metadata']);
+ if(is_array($translate->_('config__metadata'))):
+ reset($translate->_('config__metadata'));
+ $first_key = key($translate->_('config__metadata'));
?>
- var metadatas = jQuery.parseJSON('<?php echo(json_encode($config['metadata'])); ?>');
+ var metadatas = jQuery.parseJSON('<?php echo(json_encode($translate->_('config__metadata'))); ?>');
var url = jQuery.url();
var metadata_key = url.fparam('metadata');
if(typeof metadata_key === "undefined" || metadata_key.length === 0) {
metadata_key = "<?php echo($first_key);?>";
- }
+ }
<?php else: ?>
- var metadatas = { metadata: {url: "<?php echo($config['metadata']);?>", duration: <?php echo($config['duration'])?>} };
- var metadata_key = "metadata";
+ var metadatas = { metadata: {url: "<?php echo($translate->_('config__metadata'));?>", duration: <?php echo($translate->_('config__duration'))?>} };
+ var metadata_key = "metadata";
<?php endif;?>
var config = {
target:"chartTimeline",
x:8,
y:418,
- width:<?php echo($config['player_width']); ?>,
- height:<?php echo($config['player_height']); ?>,
- heightmax:<?php echo($config['player_height']); ?>,
+ width:<?php echo($translate->_('config__player_width')); ?>,
+ height:<?php echo($translate->_('config__player_height')); ?>,
+ heightmax:<?php echo($translate->_('config__player_height')); ?>,
duration:metadatas[metadata_key].duration,
metadata:metadatas[metadata_key].url
};
@@ -131,7 +131,7 @@
jQueryToolTip:"<?php echo(registry_url('jquery-tools','js'));?>",
jQueryUI:"<?php echo(registry_url('jquery-ui','js'));?>",
swfObject:"<?php echo(registry_url('swfobject','js'));?>",
- cssjQueryUI:"<?php echo(registry_url('jquery-ui','css'));?>"
+ cssjQueryUI:"<?php echo(registry_url('jquery-ui','css'));?>"
});
jQuery(document).ready(function() {
@@ -156,12 +156,12 @@
});
});
- </script>
+ </script>
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-23581291-1']);
_gaq.push(['_trackPageview']);
- _gaq.push(['_setAllowAnchor', true]);
+ _gaq.push(['_setAllowAnchor', true]);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
@@ -173,7 +173,7 @@
<body>
<div id="sendUsFeedBack"><a href="<?php echo($C_feedback_form_url); ?>" target="_blank"><img src="<?php echo(URL_ROOT); ?>images/sendusfeedback.png"></a></div>
- <!-- tooltip -->
+ <!-- tooltip -->
<div id="tip">
<div id="tipcolor" style="height:10px;width:10px"></div>
<div id="tiptext"></div>
@@ -182,7 +182,7 @@
<div class="container">
<img src="<?php echo(URL_ROOT."$rep/$config[head_logo]");?>" class="logo">
<div id="minilogo" style="margin-left:85px;height:5px;top:5px;"></div>
- <ul class="menu">
+ <ul class="menu">
<li class="menuUnderline"><a href="<?php echo(URL_ROOT)?>" class="menuLink" id="Accueil">
<?php print $translate->_("Accueil"); ?></a></li>
<li class="menuUnderline"><a href="<?php echo(URL_ROOT.$rep)?>/embed_form.php" class="menuLink" id="Embeded">
@@ -194,11 +194,11 @@
<?php print $translate->_("Archives"); ?></a></li>
</ul>
- <?php if(is_array($config['metadata'])): ?>
+ <?php if(is_array($translate->_('config__metadata'))): ?>
<ul id="content_select_ul" class="menu mdselect">
<span><?php print $translate->_("changer de contenu"); ?></span><br/>
<select id="mdselect">
- <?php foreach ($config['metadata'] as $key => $value):?>
+ <?php foreach ($translate->_('config__metadata') as $key => $value):?>
<option value="<?php echo($key); ?>" id="mdselect_<?php echo($key); ?>" ><?php echo($value['display']); ?></option>
<?php endforeach;?>
</select>
@@ -206,7 +206,7 @@
<ul class="menu shortlang" >
<?php else: ?>
<ul class="menu lang" >
- <?php endif;?>
+ <?php endif;?>
<li class="menuUnderline"><a href="<?php echo(URL_ROOT.$rep);?>/polemicaltimeline.php?lang=ja_JP" class="menuLink" >
<img src="<?php echo(URL_ROOT)?>images/flag_jp.gif"<?php if($actual!="ja_JP"){echo("style='opacity: .5;'"); } ?> />
<?php print $translate->_("Japonais"); ?></a></li>
@@ -216,7 +216,7 @@
<li ><a href="<?php echo(URL_ROOT.$rep) ?>/polemicaltimeline.php?lang=en" class="menuLink">
<img src="<?php echo(URL_ROOT)?>images/flag_en.gif" <?php if($actual!="en"){echo("style='opacity: .5;'"); } ?> />
<?php print $translate->_("Anglais"); ?></a></li>
- </ul>
+ </ul>
<!-- EXPLICATION -->
<div class="tweetExplain" >
@@ -225,10 +225,10 @@
</div>
- <!-- INFOS SUR LA CONF
+ <!-- INFOS SUR LA CONF
<div class="tweetExplain" >
- <h3 class="tweetWriterTitle"><?php echo($config['title']); ?></h3><br/>
- <?php echo($config['description']); ?>
+ <h3 class="tweetWriterTitle"><?php echo($translate->_('config__title')); ?></h3><br/>
+ <?php echo($translate->_('config__description')); ?>
</div>
-->
@@ -268,8 +268,8 @@
<div class="footer">
<hr>
- <?php echo($config['partenaires']); ?>
- </div>
+ <?php echo($translate->_('config__partenaires')); ?>
+ </div>
</div>