All pastes #927885 Raw Edit

Stuff

public php v1 · immutable
·published 2008-03-04 16:47 UTC
rendered paste body
function form_add($arr,$lang2){	echo "<form action=\"".basename($_SERVER["PHP_SELF"])."\" method=\"post\">\n"	."<fieldset>\n"	."<legend>Definizione lingue</legend>"    ."<input type=\"hidden\" name=\"ed\" value=\"1\" />\n"    ."<select name=\"lg\">\n";	foreach($lang2 as $key=>$val)	{	  $found=false;	  for($i=0;$i<count($arr);$i++)	    if($key == $arr[$i]) 	    	$found=true;	  if(!$found)	    echo "<option value=\"".$key."\">".$val."</option>\n";	}    echo "</select>\n"    ."<label for=\"df\">Lingua predefinita</label><input type=\"checkbox\" name=\"df\" id=\"df\" />\n"    ."<input type=\"submit\" value=\"Salva\" />\n"    ."</fieldset>\n"    ."</form>\n";}