Bonjour,
Ma configuration WP actuelle
– Version de WordPress : 3.4.2
– Adresse du site : URL supprimée à la demande du posteur
Problème(s) rencontré(s) :
Je n’arrive pas à traduire le mot « Search » de mon thème, pourtant le fichier searchform.php est constitué ainsi :
<?php
// Vars
global $search_form_button;
if ($search_form_button == 'searchButton') {
$search_string = '';
} elseif (get_search_query() == '') {
$search_string = 'Search';
} else {
$search_string = get_search_query();
}
if (empty($search_form_button))
$search_form_button = 'submitButton';
?>
<div class="search">
<form action="<?php echo home_url(); ?> » method= »get »>
<div class="input_wrapper">
<input type="text" name="s" onclick="clearInput(this, 'Search');" value="<?php echo $search_string; ?> » />
</div>
<span class="<?php echo $search_form_button; ?>« >
<input type="submit" name="search" class="submit" value="" />
</span>
</form>
</div><!--end of search-->
Que j’ai modifié ainsi :
<?php
// Vars
global $search_form_button;
if ($search_form_button == 'searchButton') {
$search_string = '';
} elseif (get_search_query() == '') {
$search_string = '[b]Rechercher[/b]';
} else {
$search_string = get_search_query();
}
if (empty($search_form_button))
$search_form_button = 'submitButton';
?>
<div class="search">
<form action="<?php echo home_url(); ?> » method= »get »>
<div class="input_wrapper">
<input type="text" name="s" onclick="clearInput(this, '[b]Rechercher[/b]');" value="<?php echo $search_string; ?> » />
</div>
<span class="<?php echo $search_form_button; ?>« >
<input type="submit" name="search" class="submit" value="" />
</span>
</form>
</div><!--end of search-->
Mais rien n’y fait, si vous allez tester sur le site, le formulaire se trouve en haut à droite, « Search » reste en place. J’ai manqué quelque chose ?