It would be good if there was a question type which
instead of being displayed would be actually run as php
code.
I have hacked this up for myself as a temporary
measure. Basically in our system if somebody creates a
SectionText question and the text starts with
RUN_ME_PLEASE then the text is run as php. For
example is a SectionText had its value as:
RUN_ME_PLEASE
include "blah.php";
Then whatever displays as a result of blah.php will be
displayed. This is a great way to extend the functionality
of the surveys. This is done by hacking the
render_survey.php file to contain in the $tid=100 section
the following:
<td class="qnInner" width="100%" height="35"><?
if(substr($question['content'],0,13)=="RUN_ME_PLEASE")
{
eval(substr($question['content'],13));
}else{
echo $question['content'];
}
?></td>
instead of the <td>blah blah blah it had</td>
So it would be good if there was a type which did this
automatically.
Sure this could be security hole. But you could make it so
that it is disabled.
Logged In: YES
user_id=39444
Could you explain why you need dynamic content?