GithubHelp home page GithubHelp logo

dheia / wn-faq-plugin2 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from aic-bv/wn-faq-plugin

0.0 0.0 0.0 152 KB

WinterCMS (multilingual) Frequently Asked Questions, with categories, featured statusses, search functionality and language filter

PHP 57.10% HTML 42.90%

wn-faq-plugin2's Introduction

FAQ plugin

Create Frequently Asked Questions with ease! These can be translated if you are using Winter.Translate.

Note that if you are NOT using Winter.Translate, everything will work exactly the same but the 'Translated FAQs only' checkbox will be useless and there will be no translation support.

Note:

Images

FAQ list

FAQ edit

Features

With the FAQ plugin, you can:

  • Create and update your FAQ
  • Create and update categories for your FAQ
  • Assign categories to your FAQ
  • Define questions and answers in your FAQ
  • Control which FAQs are published
    • Published
    • In progress (allows logged in backend users to see them on the frontend)
    • Hidden
  • Add a featured status to FAQ
    • Featured
    • Not featured
  • Choose the sorting method between predefined choices
    • Category (ascending and descending)
    • Created at (ascending and descending)
  • Choose which categories you wish to display
    • Your own created category
    • Your own other created category
    • Your own other other created category
    • ...
    • All
  • Choose which FAQs type you wish to display
    • Featured
    • Not featured
    • All
  • Enable a search field, allowing users to quickly find FAQs
  • Define the minimum amount of records that are required for displaying the search field
  • Make sure that only FAQs in the correct language are shown
    • for example: if FAQ #1 is NOT translated in Spanish, it won't show when the user's locale is Spanish
    • for example: if FAQ #2 is translated in Spanish and English, it will show in both Spanish and English, but not in French.
  • The default markup makes use of HTML5 details & summary
    • This adds default behaviour for opening and closing FAQs
  • Translate FAQs

Default behaviour:

  • Automatically displays all FAQ catagories
  • Automatically displays all FAQs regardless of their featured status
  • Automatically adds a search box if there are more than 10 FAQs in total
    • You can change this on the component itself by changing 'Search minimum results'.
    • Not shown if 'Search enabled' is unchecked
  • Automatically hides FAQs that are not translated in the current website langauge
    • You can change this on the component itself by unchecking 'Translated FAQs only'.

Installation

You can (soon) install this plugin for free using WinterCMS Marketplace or (now) using composer (composer require aic/wn-faq-plugin and php artisan winter:up). You can then go to 'CMS -> Components' to drag and drop FAQ in to your page/layout. Clicking the FAQ component gives you the options to modify the default behaviour.

FAQ variables

In the component itself you can use the following variables (note that you should prepend them with {{ __SELF__ }} if you have multiple FAQ components on one page):

  • items (array of items)
    • name (= category name)
    • faqs (array of faqs)
      • id
      • category_id
      • is_published
      • is_featured
      • question
      • answer
      • created_at
      • updated_at
  • isSearch (if true, searchbox is enabled)
  • searchLabel (label for the search field)
  • searchPlaceholder (placeholder for the search field)
  • minSearchResults (the minimum amount of results required for displaying the searchbox)
  • searchQuery (the querystring user used in the search box)

Let me know what you think

I spent a lot of time making this plugin public for the community. All I ask in return is that you let me know that you are using my plugin. I'm sure you all understand that it is very nice for me to know if my plugin is being used or not (might make more in the future if people actually use my plugins).

You can do so by sending me a simple message on Discord (Makalele#4465) or an e-mail to [email protected]. It doesn't have to be much, a thank you is all I ask for :)

Special thanks

Special thanks to the WinterCMS maintainer team for making this possible:

wn-faq-plugin2's People

Contributors

aic-bv avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.