Hi
I am getting the following error when submitting a question.
Notice: Trying to get property of non-object in /wp-content/plugins/dw-question-answer/inc/User.php on line 152
Notice: Trying to get property of non-object in /wp-content/plugins/dw-question-answer/inc/User.php on line 152
Warning: Cannot modify header information – headers already sent by (output started at /wp-content/plugins/dw-question-answer/inc/User.php:152) in /wp-includes/pluggable.php on line 1174
WP Version – 4.6.1
Theme – TwentyFourteen
Hope you can solve this for me as your plugin looks great so far..
Kind Regards
SimonPayne
Hi,
Please go to /wp-content/plugins/dw-question-answer/inc/User.php
and replace the code at the 152 from
if ( 'dwqa-answer' == $post->post_type || 'dwqa-question' == $post->post_type ) {
to
if ( isset( $post->ID ) && ( 'dwqa-answer' == $post->post_type || 'dwqa-question' == $post->post_type ) ) {
Thank you this has solved the issue
Great Support and Plugin
Simon
Same problem here:
WordPress 4.6.1
DWQA 1.4.5
This solution worked here too! Thank you.
Please login or Register to submit your answer