AnsPress Docs

General FAQ

A list of some commonly asked questions by people while using AnsPress. Feel free to ask for support at http://anspress.io/questions/ask/ if you have any kind of issue, feature request or bug report.

Getting 404 error
Make sure base page is selected in wp-admin->anspress->options. Save permalink once. Make sure the base page is not set to home page.
How to add social login ?
You need to install WordPress social login plugin for social login.
What is shortcode ?
[anspress] is main shortcode of AnsPress.
How to show AnsPress in home page ?
Create a new page and add [anspress] in it and save. Now set this page as home page. But do not set AnsPress base page as home page.
How to enable email notification ?
You can install AnsPress Email extension to enable email notification.
How to enable categories
You have to install our extension Categories for AnsPress for category support in AnsPress.
How to enable tags
You have to install our extension Tags for AnsPress for tags support in AnsPress.

Syntax Highlighter

By default AnsPress sanitize and preserve code in question and answer, but code button and syntax highlighter is not there by default. To get this enabled you have to follow below steps:

  1. Install Crayon Syntax Highlighter plugin and activate it. Go to http://YOUR_DOMAIN.com/wp-admin/options-general.php?page=crayon_settings.
  2. Find Decode HTML entities in code and check checkbox.
  3. Find Display the Tag Editor in any TinyMCE instances on the frontend (e.g. bbPress) check checkbox.
  4. Find Display Tag Editor settings on the frontend uncheck checkbox.
  5. And finally save the option.

After completing above steps you can see code button in ask and answer form. Let us know if need more help http://anspress.io/questions/ask/

Icons

AnsPress includes a customized set of icons coming from IcoMoon. You can either just use some of the included icons, expand the set with new icons or use a custom icons library like FontAwesome.

Using included set of icons

You can find all included font icons on the AskBug theme demo page. To use them, just copy their class name (for example “apicon-home”) and add it to the targeted “class” element in your html code. Here are some examples.
Example #01 : <span> tag

Example #02 : <i> tag

Example #03 : link

Adding more icons to included set

You can easily add new icons to AnsPress default set by using the IcoMoon library.

  1. Go to IcoMoon app.
  2. Drag and drop the anspress.svg file located in /wp-content/plugins/anspress-question-answer/theme/default/fonts/fonts to the IcoMoon window open in your browser.
  3. Select all icons from the AnsPress set using the hamburger menu on the right.(Note: not selecting all of AnsPress default icons might result in display issues – it is *NOT** recommended)*
  4. Select any other icons you need on the page.
  5. Click on « Generate Font » at the bottom of the screen.
  6. Check everything is ok and click on « Download » at the bottom of the screen.
  7. Unzip the downloaded file and find the « Fonts » folder (icomoon > Fonts).
  8. Rename all 4 files to « anspress » instead of « icomoon » (be careful not delete files extension).
  9. Replace the 4 files in located in /wp-content/plugins/anspress-question-answer/theme/default/fonts/fonts with the 4 files you just dowloaded and renamed.

You should now be able to use the class of any icon you added to the set.

Using a different icons library – Example with FontAwesome

If you wish to use a different icons library than Icomoon, you can do so by following instructions from said library. For the purpose of clarity, let’s see one way to include the FontAwesome library in your website.

  1. Go to FontAwesome Get Started page.
  2. Download FontAwesome by clicking on the “Download” button in the Download & Customize section.
  3. Unzip the file and copy the entire font-awesome directory into your project.
  4. In the <head> of your html, reference the location to your font-awesome.min.css like this:
  5. You can now used your icons the same way as the IcoMoon library or you can find new ideas by checking FontAwesome Examples page.

 

Thanks to @Fred-FLQ for writing detailed instructions.

Next Topic "Customization" »