712 Commits

Author SHA1 Message Date
Derick Rethans
141680d383 Fixed whitespace 2023-11-15 15:20:25 +00:00
Derick Rethans
0a14027c66 Fixed PHP syntax 2023-11-15 15:20:15 +00:00
Peter Kokot
6b9833ed9f Move package info pages to template 2019-01-27 13:03:02 +01:00
Peter Kokot
956d298c91 Move Release service class to container 2019-01-25 23:46:21 +01:00
Peter Kokot
e98cb34ebc Move Rest generator service to container and resolve circular reference 2019-01-25 22:18:39 +01:00
Peter Kokot
95fe965bf3 Implement dependency injection container globally
This patch implements dependency injection container in the bootstrap file.
2019-01-25 20:28:48 +01:00
Peter Kokot
5ed911a14f Bump copyrights and license year range to 2019 2019-01-25 00:22:14 +01:00
Peter Kokot
aabb5a0145 Use template engine on news page 2019-01-05 13:03:15 +01:00
Peter Kokot
27a34868ea Refactor docs pages to use template engine 2019-01-05 00:50:52 +01:00
Peter Kokot
fdba9e04c1 Sync checking admin level accross app
The ::isAdmin() method is currently used across the app. This patch uses
that instead of the Auth::check() method.
2018-12-13 00:18:25 +01:00
Peter Kokot
f7168d8348 Refactor Auth dependencies and add initSession() method
This patch moves some dependencies to constructor instead of separate
setters and adds an Auth::iniSession() method.
2018-12-13 00:05:27 +01:00
Peter Kokot
71e1df293c Remove karma functionality from the rest generator
Karma is not needed for the Rest generator service because current pecl
application uses only two user levels (admins and maintainers).

Additional change in this context:
- Partioal dependencies injected via class constructor.
2018-12-12 22:26:40 +01:00
Peter Kokot
d9a602e2b5 Add Extractor utility
This patch adds extractor service class for retrieving file contents
from the tar gzip archives (tgz). Instead of a pure PHP implementation
Archive_Tar PEAR package it uses Phar and zlib extensions to retrieve
contents from the phar stream.
2018-12-06 15:52:22 +01:00
Peter Kokot
7be4f4dbc9 Refactor files uploading
This patch removes dependency of the deprecated HTTP_Upload PEAR package
and replaces it with a lighter version of a dedicated uploader service
class instead.
2018-12-02 13:06:35 +01:00
Peter Kokot
8cf39c47be Remove deprecated PEAR_Common usage 2018-11-25 01:07:28 +01:00
Peter Kokot
788b92f59b Remove Pager dependency
This patch simplifies the Pager dependency and adds a new Pagination
class for this purpose.
2018-11-22 23:19:59 +01:00
Peter Kokot
9269da80ad Remove Net_URL2 dependency
This patch simplifies handling page redirections.
2018-11-22 02:22:46 +01:00
Peter Kokot
13145f3fec Refactor authentication functions to class
This patch moves authentication functions to a new Auth class with PHP
5.6 support.

Additionally the md5() password checking has been replaced with newer
password_hash when editing passwords on user account page.
2018-11-22 01:47:44 +01:00
Peter Kokot
0d95106cb9 Revert "Refactor authentication functions to class"
This reverts commit 2d55df3079.

The newly refactored authentication doesn't work online.
2018-11-22 01:14:55 +01:00
Peter Kokot
2d55df3079 Refactor authentication functions to class
This patch moves authentication functions to new Auth class.

Additionally the md5() password checking has been replaced with newer
password_hash when editing passwords on user account page.
2018-11-22 00:23:16 +01:00
Peter Kokot
e18f0b4ab7 Migrate user to PDO
This patch now concludes migration to PDO.
2018-11-20 03:44:03 +01:00
Peter Kokot
31632f2b82 Migrate package to PDO 2018-11-19 22:11:38 +01:00
Peter Kokot
74c96922c9 Refactor fetching users 2018-11-19 01:41:30 +01:00
Peter Kokot
2e0dc85ec4 Migrate more files to PDO 2018-11-18 21:37:55 +01:00
Peter Kokot
f6d5cf52e7 Move listing all categories to repository 2018-11-18 18:24:13 +01:00
Peter Kokot
5f7fe3741d Rename PEAR_* keys to PECL_* for consistency 2018-11-18 06:15:58 +01:00
Peter Kokot
dd0f843f69 Migrate pear-format helper to PDO 2018-11-17 21:51:36 +01:00
Peter Kokot
5fcf096a90 Migrate Rest generator to PDO 2018-11-17 21:34:08 +01:00
Peter Kokot
661c4d3aa7 Enable PDO for all files 2018-11-17 20:38:50 +01:00
Peter Kokot
50a0182d07 Refactor bootstrap initializations 2018-11-17 20:25:28 +01:00
Peter Kokot
6215e0157e Migrate accounts.php to PDO 2018-11-17 14:02:03 +01:00
Peter Kokot
5697cdef1d Migrate account-request.php to PDO 2018-11-17 10:54:26 +01:00
Peter Kokot
ce410385e5 Add agregated package stats repository 2018-11-17 05:48:11 +01:00
Peter Kokot
597f217f64 Refactor Release repository to use PDO 2018-11-17 03:58:25 +01:00
Peter Kokot
58f7b2e0ca Sync images location to img from gifs
Images include gifs, PNGs, jpges so img is more universal name for
images in the public_html.
2018-11-17 03:35:48 +01:00
Peter Kokot
145aa6078e Use single favicon.ico file in document root 2018-11-17 03:28:52 +01:00
Peter Kokot
61d696cc6b Enable PDO in CLI scripts 2018-11-17 01:56:25 +01:00
Peter Kokot
f66b4e0ce3 Add lang attribute to html root element for screen readers 2018-11-17 00:39:36 +01:00
Peter Kokot
2810c64eb2 Migrate json.php to PDO 2018-11-17 00:26:48 +01:00
Peter Kokot
10e95b4602 Migrate wishlist to PDO 2018-11-17 00:01:20 +01:00
Peter Kokot
74dc512c55 Add categoires repository 2018-11-16 23:19:46 +01:00
Peter Kokot
d4f485c129 Add users repository 2018-11-16 22:10:12 +01:00
Peter Kokot
1da9b3e980 Refactor package stats repository to use PDO 2018-11-16 20:17:02 +01:00
Peter Kokot
1d085278d2 Refactor error_reporting()
This moves all error reporting configuration currently applied in a
single place in the bootstrap based on the environment this app is
running. Additionally the approach of displaying errors has been
defined to display errors in development environment and not in
production. In production these should be logged in a file or similar.
2018-11-16 18:52:03 +01:00
Pavel Dyakonov
256d507390 use html5 doctype and utf-8 2018-11-16 16:37:36 +03:00
Peter Kokot
a90f1d4d0c Move use statement to proper place 2018-11-16 06:35:49 +01:00
Peter Kokot
14160ee422 Remove get() function
The get() function was used in one form to get eith POST or GET data
value. It's not needed and therefore removed.
2018-11-16 06:23:37 +01:00
Peter Kokot
520c3fa1ef Remove DEVBOX in favor of the configuration value 2018-11-16 05:43:21 +01:00
Peter Kokot
a7ec997ee0 Remove report_success()
The report_success() is just a simple wrapper around printing a div with
class and success message.
2018-11-16 04:51:53 +01:00
Peter Kokot
cc7ba6f0fc Refactor display_user_notes() to repository
This patch adds a simple database adapter using PDO and migrates the
display_user_notes() function into a repository class.
2018-11-16 03:51:06 +01:00