Giter Club home page Giter Club logo

laravel-questionanswer's Introduction

About

Vote based Question & Answer site built using Laravel 5.4, material design, x-editable, jQuery Upvote and email/database notifications.

Registered users can submit questions, answer questions, vote on questions & answers and when an answer is posted to a question the author is notified via email. Users will also be notified about votes, but only viewable in the their profile.

Demo: http://qna.therealjag.com

Tech

Install

  • Clone Project git pull https://github.com/TheRealJAG/Laravel-QuestionAnswer.git
  • Copy contents of .env.sample to .env using cat .env.example >> .env
  • Edit environment file vim .env
  • Run Composer Install composer install
  • Generate Key php artisan key:generate
  • Run Laravel Migrations php artisan migrate

Docker LAMP

Features

General
  • Email Notification - When a question is answered, an email notification is sent to question owner.
  • Database Notification - When a question is answered/voted or an answer is voted a notification is sent to the browser. See your notifications in the user drop down.
  • Mobile Friendly UI - Responsive design with column ordering!
  • SEO Friendly URLs - Remove stop words from the URL string.
Question
  • Top & New Pages
  • Assign Tag(s)
  • Email Notifications
  • Upvote / Downvote
Answer
  • Upvote / Downvote
  • Inline Edit
  • Rank by Votes
Tags
  • Newest Questions
  • Top Scoring Questions
  • Most Answered Questions
  • Unanswered Questions
User
  • User Registration
  • User Profile
Testing
  • Yes! - See tests directory...

License

This software is open-sourced software licensed under the MIT license.

Screenshots

The screenshots could be out of date. Check the demo site for the latest.

Alt text Alt text Alt text

laravel-questionanswer's People

Contributors

bryanrscott avatar itepifanio avatar ordago avatar therealjag avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

laravel-questionanswer's Issues

Build notifications and action logging

Notifications to a user if a question/answer is upvoted/downvoted, leaves answer...

  • In Browser, use vue?
  • Email
  • Chrome

A pivot table should do the trick.

Upgrading to Laravel 5.7 - develop branch - Migration data broken with foreign key

I'm getting the following when installing the develop branch which upgrades to laravel 5.7

Migrating: 2017_06_03_223031_notifications_foreign_key In Connection.php line 664: SQLSTATE[HY000]: General error: 1215 Cannot add foreign key constraint (SQL: alter table notificationsadd constraintnotifications_notifiable_id_foreign foreign key (notifiable_id) references users (id`) on delete cascade)

In Connection.php line 458: SQLSTATE[HY000]: General error: 1215 Cannot add foreign key constraint
`

Database\QueryException Error while colning the project

I have Database\QueryException Error:
SQLSTATE[42000]: Syntax error or access violation: 1055 'qa_laravel.questions.user_id' isn't in GROUP BY (SQL: select `questions`.*, sum(votes.vote) as vote_ttl from `questions` inner join `votes` on `questions`.`id` = `votes`.`question_id` where `questions`.`created_at` >= 2013-04-29 02:10:22 group by `questions`.`id` order by `vote_ttl` desc, `questions`.`created_at` desc limit 3)

Anyone can help me how to fix it?

Votes Migration

Just wondering if there should be a migration for the votes model?

Voting for guests

It's strange that the vote count increases / decreases when you click on the corresponding buttons, although after that a modal window appears with the message that you can only vote registered, and of course, after the page has been reloaded, the vote counter is the same as it was.

I think it's better to hide the voting buttons at all unregistered.

SQL issues

SQLSTATE[42S02]: Base table or view not found: 1146 Table 'qadb.votes' doesn't exist (SQL: select questions.*, sum(votes.vote) as vote_ttl from questions inner join votes on questions.id = votes.question_id where questions.created_at >= 2013-04-29 02:10:22 group by questions.id order by vote_ttl desc, questions.created_at desc limit 3)

New question form not submitting

@TheRealJAG Hello! I'm getting a bug where the new question form isn't submitting, on the demo site you link to as well as my local one. I'm seeing a js console type error that may be linked to it. Will poke around some more

Update: Looks like it's the twitter tags input js, it takes over the input field but doesn't have a "name" attr so that may be preventing it from submitting - when I remove that field, the request goes through

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.