I am inside the filter_answer() function and want to get the url of the question, how can i do that ? here is what i have done that has nothing to do with q2a functions and strongely does not work !!
function filter_answer(&$answer, &$errors, $question, $oldanswer) {
$url = @( $_SERVER["HTTPS"] != 'on' ) ? 'http://'.$_SERVER["SERVER_NAME"] : 'https://'.$_SERVER["SERVER_NAME"];
$url .= $_SERVER["REQUEST_URI"];
echo " the current question url is" . $url
}
is there a more appropriate way to do it, using q2a core function to retreive the question url ?
Thank you