<?php
include 'config.php';
include 'func.php';
head();

echo head . 'Тест' . div . katalog;

if (isset($_POST['submit'])) {
    
    if ($_POST['msg'] == 'Oops') {
    echo '<script type="text/javascript">';
    echo 'alert("Супер вообще:))")';
    echo '</script>';
    } else {
    echo '<script type="text/javascript">';
    echo 'alert("Что то не то))")';
    echo '</script>';        
    }
    
}

echo '<form action="g.php" method="post" name="form">';
echo '<textarea id="tarea" name="msg" cols="30" rows="5" style="width: 99%;"></textarea><br/>';
echo '<input name="submit" type="submit" class="button" value="OK" /></form>';

navig();
foot();
?>