Quote:
Originally Posted by dknelson
OK.....thanks. I understand my problem now. Here is the php for my custom "location" question. As you can see, there are no question hashes. So I need to add question hashes to all of these answers. Do I just assign them manually?
|
No question hashs are to identify a question's output. Your custom question should be this:
For usa restaurant reviews form
PHP Code:
$answer = '<select name="'.$formbit[id].'">';
$answer .= '<option></option>';
$thisanswer = $q[$formbit[id]];
$threads = $db->query_read("SELECT * FROM " . TABLE_PREFIX . "thread
WHERE forumid = '111'
ORDER BY title ASC");
while($row = $db->fetch_array($threads)) {
$answer .= '<option value="'.$row[threadid].'"';
if ($row[threadid] == $thisanswer) {
$answer .= ' selected="selected"';
}
$answer .= '>'.htmlspecialchars($row[title]).'</option>';
}
$answer .= '</select>';