im doing a search engine.Having 2 radio buttons "Title" and "Keyword" . I need to implement a checkbox too. Checkbox to search for "exact Phrase".
$queryKeyword = "SELECT * FROM document WHERE 1";
if($radio == "title")
{
$queryKeyword .= " and Title LIKE '$trimmedKeyword' ORDER by Title ASC";
}
if($radio == "keyword")
{
$queryKeyword .= " and DocNo REGEXP '[[:<:]]{$searchword}[[:>:]]' OR Title REGEXP '[[:<:]]{$searchword}[[:>:]]' OR DocType REGEXP '[[:<:]]{$searchword}[[:>:]]' OR DocDescription REGEXP '[[:<:]]{$searchword}[[:>:]]' OR AircraftType REGEXP '[[:<:]]{$searchword}[[:>:]]'ORDER by DocNo";
}
[form]
<input type="radio" name="choice" value="title">
Title</label>
<input type="radio" name="choice" value="keyword" checked>
Keyword</label>
[/form]
how can i allow the checkbox to work with the keyword radio button?