web/wp-content/themes/IRI-Theme/search.php
changeset 170 8e3a5a6fc63e
parent 136 bde1974c263b
equal deleted inserted replaced
169:2d410dc8c1f3 170:8e3a5a6fc63e
     4 	<!--  -->
     4 	<!--  -->
     5 	<?php 
     5 	<?php 
     6 		$search_text = utf8_decode(stripslashes($_GET['s']));
     6 		$search_text = utf8_decode(stripslashes($_GET['s']));
     7 
     7 
     8 		if (isset($_GET['engine'])){
     8 		if (isset($_GET['engine'])){
       
     9 		
     9 			$engine = $_GET['engine'];
    10 			$engine = $_GET['engine'];
    10 
    11 
    11 			if ($engine=="0") {
    12 			if ($engine=="0") {
    12 				
    13 				
    13 
    14 
    14 			} else if ($engine=="1") {
    15 			} else if ($engine=="1") {
    15 
    16 
    16 				$title = str_replace("%s", $search_text,__("Search results for &#8220;%s&#8221;"));
    17 				$title = str_replace("%s", $search_text,__("Search results for &#8220;%s&#8221;",'IriTheme'));
    17 				
    18 				
    18 				echo ("
    19 				echo ("
    19 					<h2 class='pagetitle'>".$title ."</h2><br/>
    20 					<h2 class='pagetitle'>".$title ."</h2><br/>
    20 					<!-- Google Custom Search Element -->
    21 					<!-- Google Custom Search Element -->
    21 						<div id=\"cse\" style=\"width:100%;\">Loading</div>
    22 						<div id=\"cse\" style=\"width:100%;\">Loading</div>
    46 		//echo ("========== ".$engine);
    47 		//echo ("========== ".$engine);
    47 	?>
    48 	?>
    48 	
    49 	
    49 	<!-- LIGNE DE TEMPS / ENMI :: RESEARCH -->
    50 	<!-- LIGNE DE TEMPS / ENMI :: RESEARCH -->
    50 	<?php if ($engine=="2") : ?>
    51 	<?php if ($engine=="2") : ?>
    51 				<h2 class='pagetitle'><?php echo(str_replace("%s", $search_text,__("Rechercher dans les annotations des ENMI &#8220;%s&#8221;"))); ?></h2>
    52 				<h2 class='pagetitle'><?php echo(str_replace("%s", $search_text,__("Rechercher dans les annotations des ENMI &#8220;%s&#8221;",'IriTheme'))); ?></h2>
    52 				<script src="http://amateur.iri.centrepompidou.fr/nouveaumonde/static/js/jquery.DOMWindow.js" type="text/javascript">
    53 				<script src="http://amateur.iri.centrepompidou.fr/nouveaumonde/static/js/jquery.DOMWindow.js" type="text/javascript">
    53 				</script>
    54 				</script>
    54 				<script type="text/javascript">// <![CDATA[
    55 				<script type="text/javascript">// <![CDATA[
    55 					function launch_search($) {
    56 					function launch_search($) {
    56 						$.openDOMWindow({
    57 						$.openDOMWindow({
    85 				// ]]></script>
    86 				// ]]></script>
    86 				<div class="box">
    87 				<div class="box">
    87 					<div>
    88 					<div>
    88 						<div id="search">
    89 						<div id="search">
    89 							
    90 							
    90 							<h6>Rechercher dans les anotations des Entretiens du nouveau monde industriel :<h6>
    91 							<h6><?php _e("Rechercher dans les anotations des Entretiens du nouveau monde industriel :",'IriTheme'); ?><h6>
    91 							
    92 							
    92 							<form id="search_form" action="http://amateur.iri.centrepompidou.fr/nouveaumonde/enmi/ldt/search/" method="post">
    93 							<form id="search_form" action="http://amateur.iri.centrepompidou.fr/nouveaumonde/enmi/ldt/search/" method="post">
    93 								
    94 								
    94 								<input name="edition" type="hidden" value="all" /> <input id="search_ts" name="ts" type="hidden" />
    95 								<input name="edition" type="hidden" value="all" /> <input id="search_ts" name="ts" type="hidden" />
    95 								<input id="s" name="search" type="text" value="<?php echo($search_text); ?>" style="width:250px;"/>
    96 								<input id="s" name="search" type="text" value="<?php echo($search_text); ?>" style="width:250px;"/>
    96 								<select id="id_type" name="type"  style="width:100px;">
    97 								<select id="id_type" name="type"  style="width:100px;">
    97 									<option value="all">tous</option>
    98 									<option value="all"><?php _e("tous",'IriTheme'); ?></option>
    98 									<option value="project">Contribution</option>
    99 									<option value="project"><?php _e("Contribution",'IriTheme'); ?></option>
    99 									<option value="content">contenu</option> 
   100 									<option value="content"><?php _e("content",'IriTheme'); ?></option> 
   100 								</select>
   101 								</select>
   101 								<select id="id_field" name="field"  style="width:100px;">
   102 								<select id="id_field" name="field"  style="width:100px;">
   102 									<option value="all">tous</option>
   103 									<option value="all"><?php _e("all",'IriTheme'); ?></option>
   103 									<option value="title">titre</option>
   104 									<option value="title"><?php _e("title",'IriTheme'); ?></option>
   104 									<option value="abstract">résumé</option>
   105 									<option value="abstract"><?php _e("resum",'IriTheme'); ?></option>
   105 									<option value="tags">tags</option>
   106 									<option value="tags"><?php _e("tags",'IriTheme'); ?></option>
   106 								</select>
   107 								</select>
   107 								<input type="submit" value="recherche" />
   108 								<input type="submit" value="recherche" />
   108 
   109 
   109 							</form>
   110 							</form>
   110 										
   111 										
   111 						</div>
   112 						</div>
   112 						<br/><br/>
   113 						<br/><br/>
   113 						<hr/>
   114 						<hr/>
   114 						<div id="msg"> 
   115 						<div id="msg"> 
   115 							Retrouvez l'ensemble des contenus et annotations et participez &agrave; l'annotation collaborative sur le site des Entretien &agrave; l'adresse suivante :<br/>
   116 							<?php _e("Retrouvez l'ensemble des contenus et annotations et participez &agrave; l'annotation collaborative sur le site des Entretien &agrave; l'adresse suivante :",'IriTheme'); ?><br/>
   116 							<a href="http://amateur.iri.centrepompidou.fr/nouveaumonde/enmi/conf/program/2009_2" target="_blank">http://amateur.iri.centrepompidou.fr/nouveaumonde/enmi/conf/program/2009_2</a>
   117 							<a href="http://amateur.iri.centrepompidou.fr/nouveaumonde/enmi/conf/program/2009_2" target="_blank">http://amateur.iri.centrepompidou.fr/nouveaumonde/enmi/conf/program/2009_2</a>
   117 						</div>
   118 						</div>
   118 						<div class="cleaner"> &nbsp;</div>
   119 						<div class="cleaner"> &nbsp;</div>
   119 					</div>
   120 					</div>
   120 				</div>
   121 				</div>
   121 	<?php endif; ?>
   122 	<?php endif; ?>
   122 	
   123 	
   123 	<!-- LIGNE DE TEMPS / AMATEURS :: SEMINAIRES -->
   124 	<!-- LIGNE DE TEMPS / AMATEURS :: SEMINAIRES -->
   124 	<?php if ($engine=="3") : ?>
   125 	<?php if ($engine=="3") : ?>
   125 				<h2 class='pagetitle'><?php echo(str_replace("%s", $search_text,__("Rechercher dans les annotations des s&eacute;minaires &#8220;%s&#8221;"))); ?></h2>
   126 				<h2 class='pagetitle'><?php echo(str_replace("%s", $search_text,__("Rechercher dans les annotations des s&eacute;minaires &#8220;%s&#8221;",'IriTheme'))); ?></h2>
   126 				<script src="http://amateur.iri.centrepompidou.fr/nouveaumonde/static/js/jquery.DOMWindow.js" type="text/javascript">
   127 				<script src="http://amateur.iri.centrepompidou.fr/nouveaumonde/static/js/jquery.DOMWindow.js" type="text/javascript">
   127 				</script>
   128 				</script>
   128 				<script type="text/javascript">// <![CDATA[
   129 				<script type="text/javascript">// <![CDATA[
   129 					function launch_search($) {
   130 					function launch_search($) {
   130 						$.openDOMWindow({
   131 						$.openDOMWindow({
   159 				// ]]></script>
   160 				// ]]></script>
   160 				<div class="box">
   161 				<div class="box">
   161 					<div>
   162 					<div>
   162 						<div id="search">
   163 						<div id="search">
   163 								<form action="http://web.iri.centrepompidou.fr/fonds/ldt/index/seminaire/__post__" method="post" id="search_form" >
   164 								<form action="http://web.iri.centrepompidou.fr/fonds/ldt/index/seminaire/__post__" method="post" id="search_form" >
   164 								  <h6>Recherche inters&eacute;minaire dans ligne de temps : <h6>
   165 								  <h6><?php _e("Recherche inters&eacute;minaire dans ligne de temps :",'IriTheme'); ?> <h6>
   165 								  <input id="s" type="text" name="value" value="<?php echo($search_text); ?>" />
   166 								  <input id="s" type="text" name="value" value="<?php echo($search_text); ?>" />
   166 								  <input type="submit" value="rechercher" />
   167 								  <input type="submit" value="rechercher" />
   167 								</form>
   168 								</form>
   168 					</div>
   169 					</div>
   169 					<div class="cleaner"></div>	
   170 					<div class="cleaner"></div>	
   173 	<?php endif; ?>
   174 	<?php endif; ?>
   174 	
   175 	
   175 	<!-- WORDPRESS / RESEARCH -->
   176 	<!-- WORDPRESS / RESEARCH -->
   176 	<?php if (have_posts() and $engine=="0") : ?>
   177 	<?php if (have_posts() and $engine=="0") : ?>
   177 	
   178 	
   178 		<h2 class="pagetitle"><?php echo(str_replace("%s", $search_text,__("Search results for &#8220;%s&#8221;"))); ?></h2>
   179 		<h2 class="pagetitle"><?php echo(str_replace("%s", $search_text,__("Search results for &#8220;%s&#8221;",'IriTheme'))); ?></h2>
   179 		
   180 		
   180 
   181 
   181 				<?php getSearch(); ?>
   182 				<?php getSearch(); ?>
   182 	
   183 	
   183 	
   184 	
   189 		<div class="clear"></div>
   190 		<div class="clear"></div>
   190 		
   191 		
   191 		<?php while (have_posts()) : the_post(); ?>
   192 		<?php while (have_posts()) : the_post(); ?>
   192 	
   193 	
   193 			<div class="post" id="post-<?php the_ID(); ?>">
   194 			<div class="post" id="post-<?php the_ID(); ?>">
   194 				<p class="large nomargin"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></p>
   195 				<p class="large nomargin"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php _e("Permanent Link to",'IriTheme'); the_title(); ?>"><?php the_title(); ?></a></p>
   195 				<?php
   196 				<?php
   196 				// Support for "Search Excerpt" plugin
   197 				// Support for "Search Excerpt" plugin
   197 				// http://fucoder.com/code/search-excerpt/
   198 				// http://fucoder.com/code/search-excerpt/
   198 				if ( function_exists('the_excerpt') && is_search() ) {
   199 				if ( function_exists('the_excerpt') && is_search() ) {
   199 					the_excerpt_rss();
   200 					the_excerpt_rss();
   218 			<div class="alignleft"><?php next_posts_link('&laquo; Previous') ?></div>
   219 			<div class="alignleft"><?php next_posts_link('&laquo; Previous') ?></div>
   219 			<div class="alignright"><?php previous_posts_link('Next &raquo;') ?></div>
   220 			<div class="alignright"><?php previous_posts_link('Next &raquo;') ?></div>
   220 		</div>
   221 		</div>
   221 	<?php elseif($engine=="0") : ?>
   222 	<?php elseif($engine=="0") : ?>
   222 	
   223 	
   223 		<h2 class="center"><?php _e("No results found."); ?></h2>
   224 		<h2 class="center"><?php _e("No results found.",'IriTheme'); ?></h2>
   224 		<?php include (TEMPLATEPATH . '/searchform.php'); ?>
   225 		<?php include (TEMPLATEPATH . '/searchform.php'); ?>
   225 		
   226 		
   226 		 <?php //	<!-- Tag Element if no result-->
   227 		 <?php //	<!-- Tag Element if no result-->
   227 			$newoptions['tcolor'] = '3466FE';
   228 			$newoptions['tcolor'] = '3466FE';
   228 			$newoptions['tcolor2'] = '3268FF';
   229 			$newoptions['tcolor2'] = '3268FF';