How to do this?

Hi,

I have put the following code in functions.php (for testing purposes, I will need to update the database) :

$metaval=”8″;
echo $metaval;
$wpdb->update( wp_2_postmeta,
array( ‘meta_value’ => $metaval),
array(‘post_id’=>720,
‘meta_key’ => ‘_ap_vote’
)

);

If I call it in footer.php, it works.

But if I call it in answer.php, it gives me a huge error :

Fatal error: Uncaught Error: Call to a member function update() on null in /home/path/site.com/wp-content/themes/wp-pravda/anspress/answer.php:71 Stack trace: #0 /home/path/site.com/wp-content/themes/wp-pravda/anspress/answers.php(57): include() #1 /home/path/site.com/wp-content/plugins/anspress-master/includes/question-loop.php(434): include(‘/home/path/si…’) #2 /home/path/site.com/wp-content/themes/wp-pravda/anspress/question.php(126): ap_question_the_answers() #3 /home/path/site.com/wp-content/plugins/anspress-master/includes/common-pages.php(118): include(‘/home/path/si…’) #4 /home/path/site.com/wp-content/plugins/anspress-master/includes/theme.php(445): AnsPress_Common_Pages::question_page() #5 /home/path/site.com/wp-content/plugins/anspress-master/includes/shortcode-basepage.php(68): ap_page() #6 /path/site.com/wp-includes/shortcodes.php(326): AnsPress_BasePage_Shortcode->anspress_sc(”, ”, ‘anspress’) #7 [internal function]: do_shortcode_tag(Array) #8 /home/path in /home/path/site.com/wp-content/themes/wp-pravda/anspress/answer.php on line 71

 

How come and how can I fix this ?

Thanks beforehand for your answer !

Hi!

  1. How can a user follow a question? Always appear 1follower and seems that it is not likely to change it.
  2. Can I configurate the notifications (not via email, just in the notifications page)? Admin should be notified when someone ask a question and it needs to be moderated before make it public.

I want that my users can be able to delete their account when they want.

Hi.

I’m working on install and configuraration of the AnsPress solution and the AskBug theme.

One thing that I’m not getting to work is “Only logged in can see questions, answer and comments?”. I have checked the  option on the “Permission” page. But unauthenticated users can still see the “Questions” page.

Any good ideas?

Gudjon

hi

can i in anspress put some speficific user status depending on the points of reputation

For ex. – if user gets 1000 rep, then he gest status like Profi or Expert, if he’s only beginer and have reputation from 0 to 1000, then he will be Newbie

If Profile is selected as NONE, when clicking the users’s name you get a double 404 error page.

Thanks

Is it possible to allow ask questions and answers for non logged users also?