PHP Web interface for generating QR codes https://qr.antopie.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

100 lines
3.6 KiB

11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
  1. # ![](themes/dark/icons/32.png) LibreQR
  2. [Lire ceci en français](README_fr.md)
  3. A PHP Web interface for generating QR codes.
  4. ## Demo
  5. A LibreQR instance is available at <https://qr.antopie.org>.
  6. ## How it works
  7. LibreQR includes an [OpenSearch](https://developer.mozilla.org/docs/Web/OpenSearch) plugin, which allows to add it as a search engine in Firefox and to save settings.
  8. You can thus generate a QR code directly from your search bar with the LibreQR's settings used at the time of adding as search engine.
  9. A [WebManifest](https://developer.mozilla.org/docs/Web/Manifest) is also included, which allows better system integration using Fennec (Firefox Android) ou Chromium.
  10. QR codes generated are located in the temp/ directory, named with the number of random characters set in config.inc.php (32 by default), and then deleted after the time set in config.inc.php (7 days by default).
  11. See `config.inc.php` for more settings.
  12. ## Installation
  13. ### Generic
  14. Just place this source code in a Web server with PHP.
  15. `wget https://code.antopie.org/miraty/libreqr/archive/1.3.0.zip`
  16. GD extension is required.
  17. `apt install php7.3-gd`
  18. LibreQR need writing rights on the `temp/` directory.
  19. ```
  20. chown -R www-data:www-data /var/www/libreqr/temp
  21. chmod -R 600 /var/www/libreqr/temp
  22. ```
  23. ### YunoHost
  24. There is [a package](https://code.antopie.org/miraty/qr_ynh/) for [YunoHost](https://yunohost.org/).
  25. For historical reasons, LibreQR is technically named `qr` in YunoHost.
  26. You can install it from the WebAdmin or with this command :
  27. ```
  28. sudo yunohost app install qr
  29. ```
  30. ## Themes
  31. ### Change theme
  32. In config.inc.php, set $theme to the wanted theme.
  33. By default, 3 themes are offered:
  34. * dark, the default dark theme. Used here: <https://qr.antopie.org>
  35. * light, the light theme.
  36. * parinux, a blue theme, made for [Bastet](https://bastet.parinux.org), the [Parinux](https://parinux.org)'s CHATON. Used here: <https://codeqr.parinux.org>
  37. ### Make a theme
  38. * Copy themes/dark to themes/[new theme's name]
  39. * Fill theme.php according to CSS colors you want
  40. * Change the source.png image according to your theme
  41. * To automatically generate favicons with the rights sizes, use `php themes/resize.php [theme's name]`
  42. This last step will need [ImageMagick](https://imagemagick.org) and [pngquant](https://pngquant.org) to be installed.
  43. ```apt install imagemagick pngquant```
  44. ## Contribute
  45. If you want to report a bug, you can open an issue at <https://code.antopie.org/miraty/libreqr/issues> after creating an account (prefered method) or contact me in another way.
  46. ## Contact
  47. If you want to contact me, for instance to report a bug or ask me a question about installing or using LibreQR, you can get my contact details on <https://miraty.antopie.org>.
  48. ## Libraries
  49. This source code includes:
  50. * [phpqrcode](https://github.com/t0k4rt/phpqrcode) to generate QR codes
  51. * [less.php](https://github.com/wikimedia/less.php) to compile [Less](http://lesscss.org)
  52. ## License
  53. [AGPLv3+](https://code.antopie.org/miraty/libreqr/src/branch/master/LICENSE)
  54. LibreQR is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
  55. LibreQR is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
  56. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
  57. You should have received a copy of the GNU Affero General Public License along with this program. If not, see <https://www.gnu.org/licenses/>.