Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+2 votes
379 views
in Q2A Core by
closed by

Warning: Use of undefined constant question - assumed 'question' (this will throw an Error in a future version of PHP) in C:\xampp\htdocs\JeeNeetQnA\qa-include\qa-base.php(720) : eval()'d code on line 120

Warning: Use of undefined constant question - assumed 'question' (this will throw an Error in a future version of PHP) in C:\xampp\htdocs\JeeNeetQnA\qa-include\qa-base.php(720) : eval()'d code on line 23

I think this is related to this

https://github.com/q2a/question2answer/blob/4344721c138e7f6845a8129278c9d3374daee085/qa-include/qa-base.php#L709

Q2A version: v1.8.5
closed with the note: solved

1 Answer

+2 votes
by
selected by
 
Best answer

Ignore the line 720 error. You should care about "code on line 23". That means there is a plugin layer that has an error in line 23. Look for enabled plugins only, then open qa-plugin.php for each and check the layers being loaded and one by one look for line 23.

Alternatively, if you'are using a good IDE, just look for the red spot in the file tree :)

In this case, you seem to have the word "question" written in that line, but it is not a string. That's generating the error.

by
Thanks, I find it this is in two plugins due to this line
if ($this->template == question)
question string without quotes.
by
Nailed it! :)

Welcome to the Q&A site for Question2Answer.

If you have a question about Q2A, please ask here, in English.

To report a bug, please create a new issue on Github or ask a question here with the bug tag.

If you just want to try Q2A, please use the demo site.

Categories

...