".$LocalImageDir.$title_image_name;
elseif (strstr($title_image_name,".gif"))
$cmd="/home/hromi1/kyberia/balast/gifsicle --resize 50x_ ".$title_image." > ".$LocalImageDir.$title_image_name;
echo $cmd;
if ($cmd) exec($cmd);
}
if($submit=="save") {
if (IsSet($title_image_name)) $redakce->addArticle($HTTP_POST_VARS,$title_image_name);
else $redakce->addArticle($HTTP_POST_VARS);
}
print_r($HTTP_POST_VARS);
echo "
";
$form=new HTML_Form($PHP_SELF,"POST","","multipart/form-data");
echo "Pridanie clanku\n";
$redakce->listArticles();
echo "\n";
$form->addText("nazov","Nazov:","");
$form->addText("autor","Autor:","");
$form->addfile("title_image","Titulni Obrazok:");
$form->addSelect("id_rubrika","Rubrika",$redakce->listRubrikyArray());
$form->addSelect("gallery","Gallery",$redakce->listGalleryArray());
$form->addSelect("id_rubrika_secondary","Sekundarna rubrika",$redakce->listRubrikyArray());
$form->addTextarea("short_desc","Kraktky popis","",40,6);
$form->addTextarea("text1","Text:","",40,6);
$form->addTextarea("text2","Text:","",40,6);
$form->addTextarea("text3","Text:","",40,6);
$form->addSubmit("submit","save","");
$form->addSubmit("submit","preview","");
$form->display();
echo "";
?>