<?PHP
# Main code
$language = $_GET['lang1'] ; // en prinicpe une url serait utilisé pour
// passer la variable lang1 qui peut être
// être différente de la variable lang
$tool_title = array (
'de' => 'Chemikaliensuche' ,
'en' => 'Chemical search' ,
'fr' => 'Recherche des composés chimiques'
) ;
$tool_description = array (
'de' => 'Dieses Tool ermöglicht die Suche von Artikeln über Chemikalien mit den gespeicherten Informationen in der Infobox' ,
'en' => 'This tool allows the search of articles about chemicals using information stored in the infobox.' ,
'fr' => 'Cet outil permet la recherche des articles concernant les composants chimiques en utilisant les information stockées dans l'infoboîte.'
) ;
$form_language = array (
'de' => 'Sprache' ,
'en' => 'Language' ,
'fr' => 'Langue'
) ;
$form_parameter = array (
'de' => 'Suchparameter' ,
'en' => 'Search parameter' ,
'fr' => 'Paramètre de recherche'
) ;
$form_parameter_name = array (
'de' => 'Name' ,
'en' => 'Name' ,
'fr' => 'Nom'
) ;
$form_parameter_iupac = array (
'de' => 'IUPAC Name' ,
'en' => 'IUPAC Name' ,
'fr' => 'Nom IUPAC'
) ;
$form_parameter_cas = array (
'de' => 'IUPAC Name' ,
'en' => 'IUPAC Name' ,
'fr' => 'Nom IUPAC'
) ;
$form_parameter_einecs = array (
'de' => 'EINECS-Nummer' ,
'en' => 'EINECS number' ,
'fr' => 'Numéro EINECS'
) ;
$form_parameter_forumula = array (
'de' => 'Summenformel' ,
'en' => 'Chemical formula' ,
'fr' => 'Formule brute'
) ;
$form_value = array (
'de' => 'Suchwert' ,
'en' => 'Search value,
'fr' => 'Valeur de recherche'
) ;
print "<html><body>" ;
print '<head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /></head>' ;
printf ("<h1>%s</h1>", $tool_title[$language]) ;
printf ("<h3>%s</h3>", $tool_description[$language]) ;
printf ("
<form method='post' Action="http://tools.wikimedia.de/~kolossos/templatetiger/tt-table4.php">
<table>
<tr><th>%s</th>
<td>
<input type='text' name='lang' value=''/>
</td>
</tr>
<tr><th>%s</th>
<td>
<select name='where'/>
<OPTION VALUE="Name">%s</OPTION>
<OPTION VALUE="IUPAC">%s</OPTION>
<OPTION VALUE="CAS">%s</OPTION>
<OPTION VALUE="EINECS">%s</OPTION>
<OPTION VALUE="Formula">%s</OPTION>
</td>
</tr>
<tr><th>%s</th>
<td>
<input type='text' name='is' value=''/>
</td>
</tr>
</table>
<input type='submit' name='search' value='Search' />
</form>
", $form_language[$language], $form_parameter[$language], $form_parameter_name[$language],$form_parameter_iupac[$language], $form_parameter_cas[$language], $form_parameter_einecs[$language], $form_parameter_formula[$language], $form_value[$language]) ;
print "</body></html>" ;
?>
Partager