First of all, I would try to find another way to get your input. A .doc file is not the easiest format around for just extracting some values.
The method you're trying could work, but I would mark the beginning of the question/answer as wel as the end of the question/answer. And with a combination of characters that is somewhat more distinctive. e.g.
***This is the question***
###This is the answer###
Then with the help of our trusted regular expressions you could try to extract the data.
For instance, to find the question you can use (where the $subject is the text content of your .doc file):
if (preg_match('/\\*\\*\\*(?P<question>[^*]+)\\*\\*\\*/', $subject, $regs)) {
$question = $regs[1];
} else {
$question = "Did not find a question.";
}
For the answer you could use:
if (preg_match('/###(?P<answer>[^#]+)###/', $subject, $regs)) {
$answer = $regs[1];
} else {
$answer = "Did not find an answer.";
}