asatirsen / forum
A forum module.
1.0.4
2021-05-30 13:52 UTC
Requires
- anax/anax-ramverk1-me: ^1.0.0
- anax/database-active-record: ^2.0
- anax/htmlform: ^2.0
Requires (Dev)
- phpunit/phpunit: ^7
README
Anax module for questions, answers and comments
This module can be incorporated with the Anax framework to provide a forum for asking questions, answering questions and commenting.
To install
In your composer.json do:
composer require asatirsen/forum
Integrate the module
From the root of your Anax repo run:
Simply run:
bash vendor/asatirsenforum/.anax/scaffold/postprocess.d/100_forum.bash
Or manually:
Copy the configuration files
rsync -av --exclude navbar --exclude page.php vendor/asatirsen/forum/config ./
Copy the view
rsync -av vendor/asatirsen/forum/view ./
copy the src directory
rsync -av vendor/asatirsen/forum/src ./
copy the sql directory
rsync -av vendor/asatirsen/forum/sql ./
create databases
sqlite3 data/db.sqlite < sql/ddl/user_sqlite.sql
sqlite3 data/db.sqlite < sql/ddl/tag_question_sqlite.sql
sqlite3 data/db.sqlite < sql/ddl/question_sqlite.sql
sqlite3 data/db.sqlite < sql/ddl/answer_sqlite.sql
sqlite3 data/db.sqlite < sql/ddl/tag_sqlite.sql
sqlite3 data/db.sqlite < sql/ddl/comment_sqlite.sql
Update your navigation:
Add Forum to your navbar via config/navbar/header.php and via config/navbar/responsive.php
You will need to insert the following lines of code into the items-key in the above files.
[
"text" => "Forum",
"url" => "forum",
"title" => "Första sidan, börja här.",
],
[
"text" => "Logga in",
"url" => "user/login",
"title" => "Logga in.",
],
[
"text" => "Frågor",
"url" => "question",
"title" => "Frågor",
],
[
"text" => "Taggar",
"url" => "tag",
"title" => "Taggar",
],
[
"text" => "Om",
"url" => "about",
"title" => "Om denna webbplats.",
],