Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+1 vote
577 views
in Q2A Core by

From the text input into radio, for example.

Input text

Like this

input radio

Q2A version: 1.83 - testing if html tags works <script></script>. Obviously, hackers can exploit this if you are not careful about displaying "extra field"!!!

2 Answers

0 votes
by

I finally found a solution after studying ask.php file and qa-theme-base.php.

public function form_field($field, $style)

{

if (@$field['tags'] == 'name="extra"') {
$this->output('<input type="radio" name="extra" value="" checked>  Empty Value  <input type="radio" id="extra" name="extra" value="ABC"> Value ABC   <input type="radio" id="extra" name="extra" value="XYZ"> Value XYZ');
}

else
    qa_html_theme_base::form_field($field, $style);
}

However, it will never be perfect, because when the user re-edits his question, the normal text form reappears. This is quite disturbing!

What is the function or php file that determines the layout of "question edit"? sad

...