Coder Social home page Coder Social logo

alfredoramos / phpbb-ext-imgur Goto Github PK

View Code? Open in Web Editor NEW
6.0 3.0 3.0 1.16 MB

Imgur extension for phpBB

License: GNU General Public License v2.0

HTML 13.14% PHP 62.34% CSS 5.89% JavaScript 18.56% SCSS 0.07%
phpbb phpbb-extension imgur imgur-api imgur-uploader

phpbb-ext-imgur's Introduction

About

Imgur extension for phpBB.

Build Status Latest Stable Version Code Quality Translation Progress License

With this extension you can click on the Imgur posting button and select the image(s) you want to upload.

If the upload is successful it will add the image in the topic, private message or signature content. You can choose in the Administration Control Panel to show the uploaded image as plan text or with BBCode as URL, image (default) or thumbnail.

Features

  • Change Imgur API data through ACP
  • Optionally, set an album where all the images will be uploaded to.
  • Compatibility with Advanced BBCode Box extension
  • CSRF protection
  • Administrator log on configuration changes
  • Insert BBCode/text at cursor position
  • Album download link in the ACP for backup
  • Upload progress bar
  • Compatibility with QuickReply Reloaded extension
  • Compatibility with mChat extension
  • Drop-down menu in posting box button
  • Imgur tab in posting box options
  • Drag and drop upload in Imgur tab
  • Save some user preferences using localStorage and sessionStorage
  • ACP settings to enable/disable output types

Requirements

  • PHP 7.1.3 or greater
  • phpBB 3.3 or greater
  • Composer (for development only)
  • Imgur API data (client_id and client_secret)

Support

Donate

If you like or found my work useful and want to show some appreciation, you can consider supporting its development by giving a donation.

Donate with PayPal Donate with Stripe
Donate with PayPal Donate with Stripe

Installation

  • Download the latest release
  • Decompress the *.zip or *.tar.gz file
  • Copy the files and directories inside {PHPBB_ROOT}/ext/alfredoramos/imgur/
  • Run composer install --prefer-dist --no-dev inside {PHPBB_ROOT}/ext/alfredoramos/imgur/
  • Go to your Administration Control Panel > Customize > Manage extensions
  • Click on Enable and confirm

Preview

ACP settings ACP settings API ACP output settings Topic Output menu Output tab

(Click to view in full size)

Imgur API

  • Create an Imgur account, if you don't have one already
  • Register your application at https://api.imgur.com/oauth2/addclient
  • Type an application name
  • Select OAuth 2 authorization with a callback URL
  • Set Authorization callback URL to http://domain.tld/app.php/imgur/authorize, use https:// if you have an SSL certificate
  • Verify that the previous URL works
  • Type your email and a short description
  • After clicking Submit you should get a client_id and client_secret

Configuration

  • Go to your Administration Control Panel > Extensions > Imgur settings
  • Set the Client ID, Client Secret and optionally an Album
  • Click on Submit
  • Once you have the required API data, click on the authorization link shown above
  • A new window will popup to authorize the application
  • Login to your Imgur account and grant access
  • The window will close itself when it's done, or show an error message

To customize the look and feel:

  • Move into {PHPBB_ROOT}/ext/alfredoramos/imgur/
  • Copy the styles/prosilver/ directory to styles/{STYLE}/
  • Edit the file styles/{STYLE}/theme/css/imgur.css as needed

Note: If your style doesn't inherit from prosilver, you should follow the steps above even if you don't want to change any file.

Uninstallation

  • Go to your Administration Control Panel > Customize > Manage extensions
  • Click on Disable and confirm
  • Go back to Manage extensions > Imgur > Delete data and confirm

Upgrade

  • Go to your Administration Control Panel > Customize > Manage extensions
  • Click on Disable and confirm
  • Delete all the files inside {PHPBB_ROOT}/ext/alfredoramos/imgur/
  • Download the new version
  • Upload the new files inside {PHPBB_ROOT}/ext/alfredoramos/imgur/
  • Enable the extension again

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.