<?php
session_start();

$title = 'Pridaj temu';

include('funkcie.php');
include('funkcie_select.php');
include('funkcie_insert.php');
include('funkcie_update.php');
include('funkcie_delete.php');

hlavicka($title);
overenie();
navig_profil(1);

  if (isset($_POST['tema_odosli'])) {
    pridaj_temu();
    header("Location: ./home.php?f=".$_GET['f']);
    exit();
  }
?>

  <form action="tema_pridat.php?f=<?php echo $_GET['f']; ?>" method="post" name="tema_form">
    <table>
      <tr>
        <td class="tema_popis">Tema: </td>
        <td colspan="3">
          <input name="tema" type="text" value="" class=""/><br/>
        </td>
      </tr>
      <tr>
        <td class="tema_popis">Text odkazu: </td>
        <td colspan="3"><textarea rows="8" cols="80" name="popis" value="" class="" ></textarea></td>
      </tr>
      <tr>
        <td class="tema_popis">Pristupnost</td>
        <td>
          <input name="pristupnost" type="radio" value="1" id="pristupnost_0"/><label for="pristupnost_0"> Verejne</label>
        </td>
        <td>
          <input name="pristupnost" type="radio" value="2" id="pristupnost_1"/><label for="pristupnost_1"> Iba priatelia</label>
        </td>
        <td>
          <input name="pristupnost" type="radio" value="3" id="pristupnost_2"/><label for="pristupnost_2"> Na heslo</label>
        </td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td colspan="2"><input type="submit" name="tema_odosli" value="Odoslať" class="" /></td>
      </tr>
    </table>
  </form>

<?php include('paticka.php'); ?>
