<br> <hr> <div align="center"> <form action="index.php?galeria_add&add" method="post" nctype="multipart/form-data"> <table border="0" width="800"> <tr> </tr> <tr> <td class="TDpost"> </tr> <tr> <td class="TDpost"> <select name="kategoria" size="1"> </tr> <tr> </tr> <tr> <tr> <td class="TDpost"> <input type="hidden" name="MAX_FILE_SIZE" value="300000" /> <input class="PostButton" type="submit" name="submit" value="ZatwierdĽ"/> </td> </form>
i php
<?php ?php require_once('../system/smarty/Smarty.class.php'); require_once('../klasy/class.db.php'); require_once('../klasy/class.bbcode.php'); $smarty = new Smarty; $smarty->template_dir = $_home_path."../style/admin/"; $smarty->compile_dir = $_home_path.'../system/templates/templates_c/'; $smarty->config_dir = $_home_path.'../system/templates/configs/'; $smarty->cache_dir = $_home_path.'../system/templates/cache/'; { if ($_FILES['file']['type'] == "image/jpg"){ } else { } } $smarty->display('galeria_add.tpl'); ?>
i wydaje mi się że coś jest źle z przekazaniem pliku z formularza do skrytpku bo jak chce wyświetlić np. nazwe pliku przez echo to nic nie pokazuje
[php]
echo $_FILES; // EFEKT ARRAY
echo $_FILES['file']['name']; // EFEKT PUSTO