Alex Cabal
e21f411191
Emit HTTP 405 instead of HTTP 404 when posting to Ebooks
2024-12-18 13:14:48 -06:00
Alex Cabal
806939ca49
Replace Template::Emit...() functions with more generic function
2024-12-18 13:14:16 -06:00
Mike Colagrosso
f449c024ea
Add /edit endpoint to update placeholders
2024-12-18 12:58:18 -06:00
Alex Cabal
97021ce26d
Add blog post
2024-12-16 23:47:02 -06:00
Alex Cabal
5782d6ca7d
Further refine projects system
2024-12-15 23:39:23 -06:00
Alex Cabal
c7a4e34e31
Add projects index page, and more detail on placeholder pages
2024-12-14 21:12:00 -06:00
Alex Cabal
adfe07aad9
Add beginning of a project management system to placeholders
2024-12-14 19:13:03 -06:00
Alex Cabal
1a742baa51
Add CanEditEbooks benefit and clean up some PHPStan errors
2024-12-14 11:50:16 -06:00
Alex Cabal
77ce4cc6b4
Make titlecasing in <h1> and page titles consistent
2024-12-13 14:16:39 -06:00
Mike Colagrosso
1ab95df084
Add placeholders for ebooks
2024-12-13 11:46:36 -06:00
Alex Cabal
c65035630f
Add public domain day banner
2024-11-27 12:52:37 -06:00
Alex Cabal
b536ebdaee
Add blog post for Public Domain Day 2025
2024-11-26 23:14:26 -06:00
Alex Cabal
e11f2ad6b1
Adjust nofollow attribute
2024-11-26 13:41:00 -06:00
Alex Cabal
84f4b2b0bf
Add donation drive aside to download page
2024-11-25 12:03:26 -06:00
Alex Cabal
11d9d0f44a
Tweak a session variable name and update comments
2024-11-20 16:42:24 -06:00
Alex Cabal
3050ab7219
Use HTTP code enums instead of ints
2024-11-20 14:52:05 -06:00
Alex Cabal
8546039b97
Comment formatting
2024-11-15 21:40:56 -06:00
Alex Cabal
d4c7703cf0
Restructure how incorrect ebook URLs are redirected
2024-11-11 13:59:45 -06:00
Alex Cabal
ec0b81817d
Restructure some files to match new URL structure
2024-11-11 11:17:04 -06:00
Alex Cabal
b7b63a4be5
Refactor functions out of Library
2024-11-10 23:05:31 -06:00
Alex Cabal
1449148989
Switch logged in user to static typed variable instead of in $GLOBALS
2024-11-10 23:05:31 -06:00
Alex Cabal
acb30b897c
Add PropertyFromHttp trait and update codebase to use new pattern
2024-11-10 22:23:43 -06:00
Alex Cabal
c35c47b793
Add DateTimeFormat enum
2024-11-08 16:41:15 -06:00
Alex Cabal
be5574eaec
Move enums into their own namespace
2024-11-08 16:34:21 -06:00
Alex Cabal
d03d9782d1
Fixes for PD Day placeholder ebooks
2024-11-07 20:15:20 -06:00
Alex Cabal
8f17f39e1b
Clean up some PD day code
2024-11-05 16:01:44 -06:00
Alex Cabal
163ada3b09
Add placeholders for public domain day ebooks
2024-11-04 21:17:09 -06:00
Alex Cabal
60f0ea16cb
Formatting tweaks
2024-11-04 13:31:17 -06:00
Mike Colagrosso
9a4da8f961
Fix PHPStan errors for CollectionType enum
...
Use the `value` property of PHP enums to get the underlying string for functions that expect a string.
Followup to #392
2024-11-04 13:16:56 -06:00
Mike Colagrosso
6c8e819316
Implement OpenSearch feed search with FilterEbooks
2024-11-04 13:16:56 -06:00
Mike Colagrosso
807e8410b4
Use array shapes in the PHPDoc
...
This makes the extra documentation unnecessary
2024-11-04 13:16:56 -06:00
Mike Colagrosso
989dcab9f0
Implement FilterEbooks via DB
2024-11-04 13:16:56 -06:00
Mike Colagrosso
44dc65005d
Query Contributors table for GetEbooksByAuthor()
2024-11-04 13:16:56 -06:00
Mike Colagrosso
2d5e66f2f2
Get carousel books from the DB
2024-11-04 13:16:56 -06:00
Mike Colagrosso
ee29c526f8
Add a CollectionMembership class
2024-11-04 13:16:56 -06:00
Mike Colagrosso
c85db527cf
Get ebook from DB for downloads
2024-11-04 13:16:56 -06:00
Mike Colagrosso
415faeb19d
Remove unused import that should have been in #371
2024-11-04 13:16:56 -06:00
Mike Colagrosso
1fd3688621
Use Ebook::GetByIdentifier() to read ebooks
2024-11-04 13:16:56 -06:00
Mike Colagrosso
b176a68d4d
Replace TextSinglePageSizeNumber and TextSinglePageSizeUnit with TextSinglePageSizeFormatted
2024-11-04 13:16:56 -06:00
Mike Colagrosso
2098b265a8
Rename the constructor Ebook::__construct()
to static Ebook::FromFilesystem()
...
Also added `GetFoo()` methods for all the derived properties like `GetUrl()`, `GetHasDownloads()`, etc. Removed that logic from the constructor so that it's reusable in `Ebook::FromFilesystem()` and `Ebook::GetByIdentifier()`
2024-11-04 13:16:56 -06:00
Mike Colagrosso
f605a4df60
Rename Created
and Updated
in PHP code to EbookCreated
and EbookUpdated
to match the schema
2024-11-04 13:16:56 -06:00
Mike Colagrosso
41b130195f
Change size checks (like bigger than 3 MB) to use TextSinglePageByteCount, not number and units
2024-11-04 13:16:56 -06:00
Alex Cabal
19cf14c1aa
Add automatic donation drives
2024-10-17 11:58:25 -05:00
Alex Cabal
eec79712fc
Use a NOW constant instead of new DateTimeImmutable objects, and tweak how some donation drive dates work
2024-10-15 22:21:12 -05:00
Mike Colagrosso
008ffc8ccd
Fix PHPStan errors
2024-06-29 15:27:30 -05:00
Alex Cabal
6af2717773
Fix broken Unix timestamp formatting
2024-06-25 10:51:48 -05:00
Alex Cabal
97821d0dc3
Remove last traces of date functions in favor of DateTimeImmutable
2024-06-13 13:11:42 -05:00
Robin Whittleton
60300807f4
Speed up reading of “More books” links
...
The links are fine on their own, don’t need to be announced as the covers.
2024-05-30 21:35:12 -05:00
Alex Cabal
a9eab552ab
Flesh out some PHPDocs, and consistently name enums
2024-05-14 15:40:56 -05:00
Alex Cabal
70ae877dd8
Bump PHPStan check level to max and add final round of type hints
2024-05-13 10:48:05 -05:00