Why can I not echo out the value from an input text?
Posted
by
user3684783
on Stack Overflow
See other posts from Stack Overflow
or by user3684783
Published on 2014-06-02T15:23:41Z
Indexed on
2014/06/02
15:24 UTC
Read the original article
Hit count: 128
I am using Wordpress to do an auction website.
Here is what the code looks like
<form method="post" action="<?php echo ProjectTheme_post_new_with_pid_stuff_thg($pid, '1');?>">
<?php do_action('ProjectTheme_step1_before_title'); ?>
<!--////////// Project Title /////////////-->
<li>
<h2><?php echo __('Your Project Title', 'ProjectTheme'); ?>: <img src="../../images/help-icon.png" width="16" height="16" id="showhelp1"/></h2>
<div id="help1">Your Project Title should be informative and brief.</div>
<p><input type="text" style="width:90%;" class="do_input" name="project_title"
value="Enter an informative & brief title..."
onfocus="this.value = this.value=='Enter an informative & brief title...'?'':this.value;"
onblur="this.value = this.value==''?'Enter an informative & brief title...':this.value;"
/></p>
<input type="submit" class="post-button" name="project_submit1" value="<?php _e("Next Step", 'ProjectTheme'); ?> »" />
</form>
I am using a step by step form for users to fill in and I wanted to do a preview page, however I tried to use:
if(isset($_POST['project_submit1'])){
$Name = $_POST['project_title'];
echo "$Name";
}
It shows up nothing.
© Stack Overflow or respective owner