Hi. im new in php and i am building a simple site..my problem is how could i make a dynamic query in php using one txtbox to input the keyword and one button. and when i hit the submit button the information will display on other text boxes.. any suggestion would be a big help..tnx

echo "<form action = 'me.php' method = 'post'>";
echo "<input type = 'text' name = 'text1'>";
echo "<input type = 'submit' name = 'submit' value = 'Submit'>";
echo "</form>";

//variable declaration here
$text1 = $_POST['text1'];
$submit = $_POST['submit'];

//condition
if ($submit == 'Submit')
{
    //this will display the value of the textbox
    echo $text1;
}
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.