isset issue
-
I can’t get this to work and can’t figure out why.
<?php /* Template Name: Test */ ?> <?php get_header();?> <div id="mainbody"> <?php if(isset($_POST['action'])) { echo "Hi"; } else { ?> <form id="test" name="test" method="post" action=""> <p><label for="name">Name:</label> <input id="name" name="name" size="10" value="" /> </p> <p><input type="submit" value="Test" id="submit" name="submit" /></p> <input type="hidden" name="action" value="post" /> </form> <?php } ?> </div> <?php get_footer(); ?>
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘isset issue’ is closed to new replies.