Code Monkey home page Code Monkey logo

forums-app's Introduction

Home Screen

Overview

This project was created for the CSC348 Web Application Development module at Swansea University. The aim was to create a forums style website using Laravel as the framework. The project specification allowed me to demonstrate numerous development skills that are key for web development.

Features

Comment on items in the database combined with AJAX

Comment

The comment system demonstrates creating entries to the database and associating an entry with another model, in this case a comment to a post. Furthermore, by using AJAX, a request is made to update the page in real time to show the new comment, therefore a refresh is not required.

User

Additionally, posts are associated with users, and these posts can be seen on the profile of that user. This demonstrates the one to many relationship between users and posts. Additionally, only the user who created the comment can see edit and delete buttons.

CSS Framework and Pagination used

Posts

I decided to use Bootstrap as my CSS framework as I have previously used it in my projects and the extensive documentation meant it was quick for me to setup with my web application.

Using paginate on my Eloquent queries for posts, users, and communities means that the page does not get filled with every single item from the database, and allows me to easily navigate through the pages.

Service Container Pattern

Profile

As part of the extra features for the specification I used the service container pattern to implement a weather indicator on a user's profile. This container makes requests to a weather API and stores the information. This container can be accessed across the entire scope of the website meaning I can easily add the weather feature elsewhere. Furthermore it allows me to easily update the request code if the provider makes breaking changes to their API.

Multiple level of authorisation

I created two roles, a user and an admin. The admin has the ability to create, edit and delete posts, users, and communities. The user can only create posts and comments. This demonstrates the use of middleware to restrict access to certain pages. Furthermore, the admin can delete users, and this cascades to delete all posts and comments associated with that user.

To achieve this I associated certain permissions to each of these roles, meaning I can easily add new permissions without affecting current roles, and create new roles with certain permissions.

User presence

  • User registration
  • Multiple level of authorisation (user roles)

Working with data

  • Create, edit and delete items
  • Validation implemented
  • One to one, one to many and many to many relationships used
  • Images can be uploaded and stored in the database
  • Polymorphic relationships used.

forums-app's People

Contributors

mitgobla avatar

Watchers

 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.