Hello,

I am not able to display Questions listing page (base page).

ANSPRESS_TITLE

Please help.

 

Thanks

Hi,

There are following 2 bugs/issues present in Askbug v3.1.3 (I don’t know if these are appearing for me only, as no one else has reported it).

Fatal error: Call to undefined function ap_post_comments() in /<–my site–>/wp-content/themes/askbug/anspress/single-question.php on line 101

 

Fatal error: Call to undefined function is_ap_user() in /<–my site–>/wp-content/themes/askbug/templates/anspress.php on line 13

 

Only fix, I was able to do that to temporarily remove checking both functions from their respective places.

Kindly look into this.

 

AnsPress v4.1.1

 

Thanks.

Regards,

Atul

Hi,

As you know, I am planning to start from scratch, which includes adding around 60,000 Q&A programmatically. Long back I wrote a raw script to add Q&A programmatically and posted on Anspress too –

https://anspress.io/questions/question/tutorial-how-to-import-questions-and-answers-to-anspress/

But a lot has changed since then. I wanted to know what are different metas consumed when a question or answer is posted, and more importantly How to update those in a fast way(using hard coding)?

I know you had earlier suggested to some user “ap_save_question”

https://anspress.io/resources/functions/ap_save_question/

which is deprecated now. Then I read about “submit_question_form”

https://anspress.io/resources/methods/ap_form_hooks-submit_question_form/

From here I got the basic idea. But it’s very difficult to reverse trace all the metas used by this function (and sub-functions). Also, there are parts which can Not be there when adding Q&A programmatically (such as redirect to newly posted Question).

 

So I need to make a new function, which will just add new question/answer and its metas.

 

For e.g, I have just striped a part (adding question programmatically) of script which I posted earlier –

https://gist.github.com/atultiwari/f99656c899d0f1faef9125d6b0db098c

 

 

Sorry, it seems I was not able to embed codes here, so added screenshot, for better understanding.

In the above e.g., I used wp_set_post_terms for adding category & tags.

Can this be used with current version of Anspress?

So far I can think of following metas, which are being used in posting Q&A –

  1. Category
  2. Tags
  3. Activities
  4. View counts
  5. Timestamp

But, I am not sure how to use these in my script?

Please share your inputs regarding this.

 

Thanks.

Regards,

Atul

Hi,

I am testing my Anspress installation and when I post a question when I am NOT logged in as a user I am redirected to a 404 error page. However, if I click on the question from my Anspress base page the page IS live.

If I am logged in to my WP account and post a question the redirect goes to a page that is live and doesn’t show a 404 error.

What is going on? How can I set it so non-logged in registered users will be redirected to a live page as well?

 

Thanks

Hey,

I’m hoping that someone can help here, as i may be missing something simple.

I use divi builder (a page builder) on my wordpress site to help customise the layout of my pages.

So far I have successfully customised the archives, ask, user, categories and tags pages by using the divi builder then dropping in the anspress shortcode.

However I cannot seem to figure out a way to use divi builder on single question pages (ie the one you’ll be reading this question on).

I have tried to change the question slug for a single question page, then create a page with the same name and edit that, but it still wont display any divi builder layout.

What am I doing wrong?

Help would be greatly appreciated.

Cheers.

Hi,

Is it possible to make customized permalinks? What I would ideally like the permalinks to be would be to include the categories and then question name as the permalink.

For example, oursite.com/category1/this-is-a-question

oursite.com/category2/this-is-a-question etc etc

 

Is this possible?

 

Thanks!