Jump to content

echo (after submit) in same <div> as form?


paulmo

Recommended Posts

I've got a floating div with a form in it. Form works, but I need to greet user after submit. The following code is posting the greeting like html, when I need it to post after form is submitted, in same div as form. The echo is not posting inside the div. $survey variable is from radio buttons and is working (inserts in db table, etc.). Thanks in advance for help:

<div id="float"><form name= "survey" method="post" action="index.php">//etc...</form><?phpif (isset($survey)){echo "Thank you for your feedback!";}?></div>

Link to comment
Share on other sites

on submit, "index.php" is executed and the greeting will not display as written provided that I understood your question.EDIT: there must be something else in the form. The code you're showing makes it difficult to understand the context of your question.

Link to comment
Share on other sites

It's a Yahoo submit button. As mentioned it's putting the values in my db table. Thanks. <input id="submitbutton1" type="submit" name="submitfield1" value="Submit"> <script>var oSubmitButton1 = new YAHOO.widget.Button("submitbutton1", { value: "submitbutton1value" });</script>

Link to comment
Share on other sites

Still not enough code. What does the relevant part of your script look like in it's entirety?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...